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J,CAAoB5S,CAApB,CAA2BwS,CAA3B,CAAkC3S,OAAlC,CAA2C2S,CAA3C,CAAkDC,UAAlD,CAA8DD,CAA9D,CAAqE1S,MAArE,CACA,OAAO4S,EAJ4B,CAF1B,CAAZ,CAAD,EAL6C,CAA/C;", "sources":[" [synthetic:base] "," [synthetic:es6/util/createtemplatetagfirstarg] "," [synthetic:util/defines] "," [synthetic:util/defineproperty] "," [synthetic:util/global] "," [synthetic:util/shouldpolyfill] "," [synthetic:util/polyfill] "," [synthetic:es6/util/setprototypeof] "," [synthetic:es6/util/arrayiterator] "," [synthetic:es6/util/makeiterator] "," [synthetic:es6/generator_engine] "," [synthetic:es6/execute_async_generator] "," [synthetic:es6/symbol] "," [synthetic:es6/promise/promise] "," [synthetic:es6/conformance] "," [synthetic:util/owns] "," [synthetic:es6/weakmap] "," [synthetic:es6/util/iteratorfromarray] "," [synthetic:es6/array/entries] "," [synthetic:es6/promise/finally] "," [synthetic:es6/util/assign] "," [synthetic:es6/object/assign] "," [synthetic:es6/array/keys] "," [synthetic:es6/object/is] "," [synthetic:es6/array/includes] "," [synthetic:util/checkstringargs] "," [synthetic:es6/string/includes] "," [synthetic:util/findinternal] "," [synthetic:es6/array/find] "," [synthetic:es6/array/findindex] "," [synthetic:es6/object/fromentries] "," [synthetic:es6/object/entries] "," [synthetic:es6/string/startswith] "," [synthetic:es6/array/values] ","Logic.js","displayerXObjectPropertyHelper.js","editBus.js","jsonMerge.js","liveDataSource.js","polyfills.js"], "sourcesContent":["/*\n * Copyright 2012 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n\n/**\n * @fileoverview The base namespace for code injected by the compiler\n * at compile-time.\n */\n\n/** @const */\nvar $jscomp = $jscomp || {};\n\n/** @const Locals for goog.scope */\n$jscomp.scope = {};\n","/*\n * Copyright 2020 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Polyfill for a tagged template's argument\n * @suppress {uselessCode}\n */\n'require base';\n\n/**\n * Simply accepts an ITemplateArray and returns it after setting its raw\n * property\n * @param {!ITemplateArray} arrayStrings\n * @return {!ITemplateArray}\n * @noinline\n */\n$jscomp.createTemplateTagFirstArg = function(arrayStrings) {\n arrayStrings.raw = arrayStrings;\n return /** @type {!ITemplateArray} */ (arrayStrings);\n};\n\n/**\n * Simply accepts an ITemplateArray and returns it after setting its raw\n * property\n * @param {!ITemplateArray} arrayStrings\n * @param {!ITemplateArray} rawArrayStrings raw string values of arrayString\n * @return {!ITemplateArray}\n * @noinline\n */\n$jscomp.createTemplateTagFirstArgWithRaw = function(\n arrayStrings, rawArrayStrings) {\n arrayStrings.raw = rawArrayStrings;\n return /** @type {!ITemplateArray} */ (arrayStrings);\n};\n","/*\n * Copyright 2017 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require base';\n\n\n/**\n * Whether to assume ES5 is available. This enables removing several\n * internal polyfills, which must otherwise be detected at runtime.\n * @define {boolean}\n */\n$jscomp.ASSUME_ES5 = false;\n\n/**\n * Whether to skip the conformance check and simply use the polyfill always.\n * @define {boolean}\n */\n$jscomp.ASSUME_NO_NATIVE_MAP = false;\n\n/**\n * Whether to skip the conformance check and simply use the polyfill always.\n * @define {boolean}\n */\n$jscomp.ASSUME_NO_NATIVE_SET = false;\n\n/**\n * Whether to provide an incorrect but tiny Math.fround polyfill that just\n * returns the number given. This is usually okay to do, particularly if\n * `Math.fround` is only used to allow the JavaScript engine to use faster\n * 32-bit float operations, but could cause problems if program logic is\n * dependent on floats being truncated consistently.\n * @define {boolean}\n */\n$jscomp.SIMPLE_FROUND_POLYFILL = false;\n\n/**\n * Whether to isolate all injected polyfills from global state. This is not\n * on by default, as it bloats code size, but is useful when code needs to\n * operate on untrusted third_party sites. It relies on a compiler pass to\n * rewrite potential polyfill accesses.\n * @define {boolean}\n */\n$jscomp.ISOLATE_POLYFILLS = false;\n\n/**\n * Should we unconditionally override a native Promise implementation with our\n * own?\n * @define {boolean}\n */\n$jscomp.FORCE_POLYFILL_PROMISE = false;\n\n/**\n * Override the native Promise implementation if unhandledrejection event is not\n * supported.\n * @define {boolean}\n */\n$jscomp.FORCE_POLYFILL_PROMISE_WHEN_NO_UNHANDLED_REJECTION = false;\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Provides methods to polyfill native objects.\n * @suppress {reportUnknownTypes}\n */\n'require util/defines';\n\n\n/**\n * Polyfill for Object.defineProperty() method:\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/defineProperty\n *\n * Refuses to define properties on Array.prototype and Object.prototype,\n * since we can't make them non-enumerable and this messes up peoples' for\n * loops. Beyond this, we simply assign values and not worry\n * about enumerability or writeability.\n *\n * @type {(typeof Object.defineProperty)}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.defineProperty =\n $jscomp.ASSUME_ES5 || typeof Object.defineProperties == 'function' ?\n Object.defineProperty :\n function(target, property, descriptor) {\n if (target == Array.prototype ||\n // b/155133192\n /** @type {?} */ (target) == Object.prototype) {\n return target;\n }\n\n /**\n * NOTE: This is currently never called with a descriptor outside\n * the control of the compiler. If we ever decide to polyfill either\n * Object.defineProperty or Reflect.defineProperty for ES3, we should\n * explicitly check for `get` or `set` on the descriptor and throw a\n * TypeError, since it's impossible to properly polyfill it.\n */\n target[property] = descriptor.value;\n return target;\n };\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Runtime code to store the global object.\n * @suppress {uselessCode}\n */\n'require base';\n\n/**\n * Locate and return a reference to the global object.\n *\n * NOTE: This method is marked with `noinline`, because `RemoveUnusedCode` has\n * trouble removing the loop it contains if it gets inlined into the global\n * scope.\n * @param {?Object} passedInThis\n * @return {!Global} The global object.\n * @suppress {undefinedVars|reportUnknownTypes}\n * @noinline\n */\n$jscomp.getGlobal = function(passedInThis) {\n var possibleGlobals = [\n // Web Audio Worklets do not have any way to refer to their global object\n // other than `globalThis`.\n // This use of `globalThis` does not prevent removal of the `globalThis`\n // polyfill, because the usage is guarded by a typeof check.\n 'object' == typeof globalThis && globalThis,\n // Rhino (used by older Google Docs Script projects) has no `window` or\n // `self`, but `this` from the global scope is the global object. Also,\n // some GWT tests running on Rhino do have a `window` and `self` but, for\n // unknown reasons, see runtime exceptions when we return `window` instead\n // of `passedInThis`.\n // NOTE: If the compiler's output is wrapped in a strict-mode function,\n // this file's code won't actually be executing in global scope, so this\n // value will be undefined.\n passedInThis,\n // Browser windows always have `window`\n 'object' == typeof window && window,\n // WebWorkers have `self`\n 'object' == typeof self && self,\n // NodeJS has `global`\n 'object' == typeof global && global,\n ];\n for (var i = 0; i < possibleGlobals.length; ++i) {\n var maybeGlobal = possibleGlobals[i];\n // It can happen that an environment has, for example, both `global` and\n // `window` defined in the global scope, but one of them isn't actually\n // the global object, so check that it really seems to be the global object.\n // We use `Math` to check for this because it's only 4 characters long,\n // exists in all possible JS environments, and doesn't have the problematic\n // equality behavior of `NaN`.\n if (maybeGlobal && maybeGlobal['Math'] == Math) {\n return /** @type {!Global} */ (maybeGlobal);\n }\n }\n // Throw an exception if we cannot find the global object.\n // We have to be sneaky about it, otherwise the compiler will think this code\n // has a side effect (throwing an exception) that prevents it from being\n // removed, even when all usages of `$jscomp.global` get removed.\n // Casting through unknown is necessary to keep the compiler from rejecting\n // this code.\n return /** @type {!Global} */ (\n /** @type {?} */ ({\n valueOf: function() {\n throw new Error('Cannot find global object');\n }\n }.valueOf()));\n};\n\n\n/**\n * The global object.\n * @const {!Global}\n */\n$jscomp.global = $jscomp.getGlobal(this);\n","/*\n * Copyright 2020 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Helpers to decide whether to trust existing implementations of\n * polyfilled methods.\n * @suppress {uselessCode} the requires are considered \"useless\"\n */\n\n'require util/defines';\n\n/**\n * @const {boolean} whether Symbol is implemented natively (i.e. is not a\n * polyfill)\n */\n$jscomp.IS_SYMBOL_NATIVE =\n typeof Symbol === 'function' && typeof Symbol('x') === 'symbol';\n\n/**\n * Whether code should use built-in versions of ES6 methods when available.\n *\n * @const {boolean}\n */\n$jscomp.TRUST_ES6_POLYFILLS =\n !$jscomp.ISOLATE_POLYFILLS || $jscomp.IS_SYMBOL_NATIVE;\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Provides methods to polyfill native objects.\n * @suppress {uselessCode}\n */\n'require util/defineproperty';\n'require util/defines';\n'require util/global';\n'require util/shouldpolyfill';\n\n/** @const {!Object} map from classes (Map) to polyfills */\n$jscomp.polyfills = {};\n\n/**\n * Maps a property to an obfuscated look-up string for that property. Only used\n * when `$jscomp.ISOLATE_POLYFILLS is enabled.\n *\n * When compiling with polyfill isolation enabled, to polyfill an\n * `owner.prototype.method` the `$jscomp.polyfill` library function:\n *
    \n *
  1. creates an obfuscated string for `method`\n *
  2. adds the obfuscated string as a new property on the `owner` object\n *
  3. assigns the polyfill implementation of `method` to this new obfuscated\n * property on the `owner` object.
  4. \n *
\n *\n * This maps the original property name `method` to the new obfuscated property\n * name.\n * @const {!Object}\n */\n$jscomp.propertyToPolyfillSymbol = {};\n\n/** @const {string} */\n$jscomp.POLYFILL_PREFIX = '$jscp$';\n\n/**\n * Returns the polyfill function of the given property if present, otherwise\n * returns the actual property.\n *\n * This is a variable instead of a $jscomp.* property to make it simpler for\n * the compiler to avoid prematurely deleting it during optimizations.\n *\n * @param {*} target the receiver for the property access, e.g. `my.str` in\n * `my.str.includes`\n * @param {string} property the name of the property, e.g. `includes` in\n * `my.str.includes`\n * @return {?} if an obfuscated symbol for the property was added onto the\n * target, then this function returns the polyfill for the property.\n * Otherwise simply looks up the property on the target and returns it as\n * `target[key]`.\n * @noinline prevent inlining so IsolatePolyfills can find this declaration.\n * @suppress {reportUnknownTypes}\n */\nvar $jscomp$lookupPolyfilledValue = function(target, property) {\n /** @const */\n var obfuscatedName = $jscomp.propertyToPolyfillSymbol[property];\n if (obfuscatedName == null) {\n return target[property];\n }\n\n // NOTE: this will throw if `target` is null or undefined.\n /** @const */\n var polyfill = target[obfuscatedName];\n\n // Checking `polyfill !== undefined` is sufficient because $jscomp.polyfill\n // never installs nullish polyfills. Otherwise we'd have to check something\n // like `key in target`.\n return polyfill !== undefined ? polyfill : target[property];\n};\n\n/**\n * @param {string} target Qualified name of the class or method to polyfill,\n * e.g. 'Array.prototype.includes' or 'Map'.\n * @param {?function(*): *} polyfill A function that takes the current browser\n * implementation of the target and returns an optional new polyfill\n * implementation. If null is returned, then no polyfill will be added. A\n * null argument for this parameter indicates that the function will not be\n * polyfilled, and is only useful for `build_polyfill_table.js` bookkeeping.\n * @param {string} fromLang The language level in which the target is expected\n * to already be present in the browser. The compiler requires that\n * `languageOut < fromLang` before injecting a polyfill (i.e. if the\n * specified output language already includes the feature then there's no\n * need to polyfill it).\n * @param {string} toLang The language level required by the polyfill\n * implementation. The compiler will issue an error if a polyfill is\n * required, but `languageOut < toLang`. Additionally, the\n * `build_polyfill_table.js` script audits the polyfill dependency tree to\n * ensure that no polyfill with a lower `toLang` depends on one with a\n * higher `toLang`.\n * @noinline\n * NOTE: We prevent inlining so RemoveUnusedPolyfills can always recognize this\n * call.\n */\n$jscomp.polyfill = function(target, polyfill, fromLang, toLang) {\n if (!polyfill) return;\n if ($jscomp.ISOLATE_POLYFILLS) {\n $jscomp.polyfillIsolated(target, polyfill, fromLang, toLang);\n } else {\n $jscomp.polyfillUnisolated(target, polyfill, fromLang, toLang);\n }\n};\n\n/**\n * @param {string} target Qualified name of the class or method to polyfill,\n * @param {function(*): *} polyfill A function that takes the current browser\n * implementation of the target and returns an optional new polyfill\n * implementation.\n * @param {string} fromLang The language level in which the target is expected\n * to already be present in the browser.\n * @param {string} toLang The language level required by the polyfill\n * implementation.\n * @suppress {reportUnknownTypes}\n * @see $jscomp.polyfill for more documentation\n */\n$jscomp.polyfillUnisolated = function(target, polyfill, fromLang, toLang) {\n var obj = $jscomp.global;\n var split = target.split('.');\n for (var i = 0; i < split.length - 1; i++) {\n var key = split[i];\n if (!(key in obj)) return;\n obj = obj[key];\n }\n var property = split[split.length - 1];\n var orig = obj[property];\n var impl = polyfill(orig);\n if (impl == orig || impl == null) return;\n $jscomp.defineProperty(\n obj, property, {configurable: true, writable: true, value: impl});\n};\n\n/**\n * Defines a polyfill for the given class or method under an obfuscated name.\n *\n * The main differences between this method and $jscomp.polyfillUnisolated are:\n * - classes are defined on $jscomp.polyfills, not window.\n * - methods (Array.prototype.includes) are defined on Array.prototype under\n * an obfuscated name Array.prototype.$jscp$includes or a Symbol, if native.\n * - this method installs our polyfill even when an existing implementation is\n * found, as it might be an untrusted polyfill. The exception is that if\n * Symbol is detected to be native, we assume any implementations of ES6\n * classes/methods are also native and not polyfills.\n *\n * @param {string} target Qualified name of the class or method to polyfill,\n * @param {function(*): *} polyfill A function that takes the current browser\n * implementation of the target and returns an optional new polyfill\n * implementation.\n * @param {string} fromLang The language level in which the target is expected\n * to already be present in the browser.\n * @param {string} toLang The language level required by the polyfill\n * implementation.\n * @suppress {reportUnknownTypes}\n * @see $jscomp.polyfill for more parameter documentation\n */\n$jscomp.polyfillIsolated = function(target, polyfill, fromLang, toLang) {\n var split = target.split('.');\n var isSimpleName = split.length === 1;\n var root = split[0];\n\n // Look up the parent object. For classes this is just $jscomp.global.\n // For methods/properties this may be a polyfill (Promise) or may a native\n // object (Array.prototype).\n var ownerObject;\n if (!isSimpleName && root in $jscomp.polyfills) {\n // Handle Symbol.asyncIterator and Promise.prototype.finally\n ownerObject = $jscomp.polyfills;\n } else {\n // Handle Promise, Array.of, and String.prototype.startsWith\n ownerObject = $jscomp.global;\n }\n\n for (var i = 0; i < split.length - 1; i++) {\n var key = split[i];\n if (!(key in ownerObject)) return;\n ownerObject = ownerObject[key];\n }\n\n var property = split[split.length - 1];\n // If Symbol is native and the target is in the ES6 spec, use the native imp.\n // We assume the method/class was not polyfilled since polyfills typically\n // back off in the presence of an existing implementation.\n var nativeImpl = $jscomp.IS_SYMBOL_NATIVE && fromLang === 'es6' ?\n ownerObject[property] :\n null;\n var impl = polyfill(nativeImpl);\n\n if (impl == null) {\n return;\n }\n\n if (isSimpleName) {\n // Note: `impl` may be the actual native class instead of a\n // polyfill. Add it to $jscomp.polyfills anyway. The IsolatePolyfills pass\n // unconditionally replaces `Symbol` with `$jscomp.polyfills['Symbol']`.\n\n // Use $jscomp.polyfills instead of ownerObject. For simple names like\n // Promise and Symbol, ownerObject is the global object, and we want to\n // avoid adding new global variables.\n $jscomp.defineProperty(\n $jscomp.polyfills, property,\n {configurable: true, writable: true, value: impl});\n } else if (impl !== nativeImpl) {\n // Skip installing an obfuscated property if we have found a native version\n // of the method we're polyfilling. $jscomp$lookupPolyfilledValue will fall\n // back to the native version anyway.\n if ($jscomp.propertyToPolyfillSymbol[property] === undefined) {\n $jscomp.propertyToPolyfillSymbol[property] = $jscomp.IS_SYMBOL_NATIVE ?\n // use bracket access to avoid injecting the Symbol polyfill\n $jscomp.global['Symbol'](property) :\n $jscomp.POLYFILL_PREFIX + property;\n }\n\n /** @const {string} */\n var obfuscatedName = $jscomp.propertyToPolyfillSymbol[property];\n\n // Define the polyfilled method on its owner but under an obfuscated\n // name to avoid collisions. The owner will be a native class like `Promise`\n // or a native class's prototype like `Array.prototype`.\n $jscomp.defineProperty(\n ownerObject, obfuscatedName,\n {configurable: true, writable: true, value: impl});\n }\n};\n","/*\n * Copyright 2017 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview\n * @suppress {uselessCode}\n */\n\n'require util/defines';\n'require util/polyfill';\n'require util/shouldpolyfill';\n\n/**\n * @suppress {missingProperties,reportUnknownTypes}\n * @return {boolean}\n */\n$jscomp.underscoreProtoCanBeSet = function() {\n var x = {a: true};\n var y = {};\n try {\n y.__proto__ = x;\n return y.a;\n } catch (e) {\n // __proto__ property is readonly (possibly IE 10?)\n }\n return false;\n};\n\n/**\n * If we can implement it, this will be a function that attempts to set the\n * prototype of an object, otherwise it will be `null`.\n *\n * It returns the first argument if successful. Throws a `TypeError` if the\n * object is not extensible.\n *\n * @type {null|function(!Object, ?Object): !Object}\n */\n$jscomp.setPrototypeOf = ($jscomp.TRUST_ES6_POLYFILLS &&\n typeof Object.setPrototypeOf == 'function') ?\n Object.setPrototypeOf :\n $jscomp.underscoreProtoCanBeSet() ? function(target, proto) {\n target.__proto__ = proto;\n if (target.__proto__ !== proto) {\n throw new TypeError(target + ' is not extensible');\n }\n return target;\n } : null;\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Utility method for creating an iterator for Arrays.\n */\n'require base';\n\n/**\n * Returns an internal iterator from the given array.\n * @param {!IArrayLike} array\n * @return {function():!IIterableResult}\n * @template T\n */\n$jscomp.arrayIteratorImpl = function(array) {\n var index = 0;\n return function() {\n if (index < array.length) {\n return {\n done: false,\n value: array[index++],\n };\n } else {\n return {done: true};\n }\n };\n};\n\n/**\n * Returns an internal iterator from the given array.\n * @param {!Array} array\n * @return {!Iterator}\n * @template T\n */\n$jscomp.arrayIterator = function(array) {\n return /** @type {!Iterator} */ ({next: $jscomp.arrayIteratorImpl(array)});\n};\n\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Polyfill for for-of loops.\n */\n'require es6/util/arrayiterator';\n\n/**\n * Creates an iterator for the given iterable. This iterator should never\n * be exposed to user code.\n *\n * @param {string|!Iterable|!Iterator|!Arguments} iterable\n * @return {!Iterator}\n * @template T\n * @suppress {reportUnknownTypes}\n */\n$jscomp.makeIterator = function(iterable) {\n // NOTE: Disabling typechecking because [] not allowed on @struct.\n var iteratorFunction = typeof Symbol != 'undefined' && Symbol.iterator &&\n (/** @type {?} */ (iterable)[Symbol.iterator]);\n return iteratorFunction ? iteratorFunction.call(iterable) :\n $jscomp.arrayIterator(/** @type {!Array} */ (iterable));\n};\n","/*\n * Copyright 2018 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require base';\n'require es6/util/setprototypeof';\n'require es6/util/makeiterator';\n\n/**\n * @fileoverview Implementation for $jscomp.generator\n *\n * This closure-compiler internal JavaScript library provides an ES3-compatible\n * API for writing generator functions using a minimum of boilerplate.\n *\n * Example:\n * ```javascript\n * // yields numbers starting with the given value, then incrementing by the\n * // value supplied to the next() method until the computed value is <= min or\n * // >= max. Then it returns the total number of times it yielded.\n * // If the client code calls throw(), the error will be logged and then\n * // yielded, but the generator won't terminate.\n * function *es6Definition(start, min, max) {\n * let currentValue = start;\n * let yieldCount = 0;\n * while (currentValue > min && currentValue < max) {\n * try {\n * currentValue += yield(currentValue);\n * } catch (e) {\n * yield(e);\n * console.log('client threw error', e);\n * } finally {\n * yieldCount++;\n * }\n * }\n * return [yieldCount, currentValue];\n * }\n *\n * function es3Definition(start, min, max) {\n * var currentValue;\n * var yieldCount;\n * var e;\n *\n * return $jscomp.generator.createGenerator(\n * es3Definition,\n * function (context$) {\n * switch (context$.nextAddress) {\n * case 1: // execution always starts with 1\n * currentValue = start;\n * yieldCount = 0;\n * // fall-through\n *\n * case 2:\n * if (!(currentValue > min && currentValue < max)) {\n * // exit while loop:\n * return context$.jumpTo(3);\n * }\n * // try {\n * JSCompiler_temp_const$jscomp$1 = currentValue;\n * context$.setCatchFinallyBlocks(4, 5);\n * return context$.yield(currentValue, 7);\n *\n * case 7:\n * currentValue =\n * JSCompiler_temp_const$jscomp$1 + context$.yieldResult;\n * // fall-through: execute finally block\n *\n * case 5: // finally block start\n * context$.enterFinallyBlock();\n * yieldCount++;\n * return context$.leaveFinallyBlock(6);\n *\n * case 4: // catch block start\n * e = context$.enterCatchBlock();\n * return context$.yield(e, 8);\n *\n * case 8: // finish catch block\n * console.log('client threw error', e);\n * return context$.jumpTo(5);\n *\n * case 6:\n * context$.jumpTo(2);\n * break;\n *\n * case 3:\n * // come back here when while loop block exits\n * return context$.return([yieldCount, currentValue]);\n * }\n * }\n * });\n * };\n * ```\n */\n\n/** @const */\n$jscomp.generator = {};\n\n/**\n * Ensures that the iterator result is actually an object.\n *\n * @private\n * @final\n * @param {*} result\n * @return {void}\n * @throws {TypeError} if the result is not an instenace of Object.\n */\n$jscomp.generator.ensureIteratorResultIsObject_ = function(result) {\n if (result instanceof Object) {\n return;\n }\n throw new TypeError('Iterator result ' + result + ' is not an object');\n};\n\n\n/**\n * Tracks state machine state used by generator.Engine.\n *\n * @template VALUE\n * @constructor\n * @final\n * @struct\n */\n$jscomp.generator.Context = function() {\n /**\n * Whether the generator program is being executed at the moment in the\n * current context. Is used to prevent reentrancy.\n *\n * @private\n * @type {boolean}\n */\n this.isRunning_ = false;\n\n /**\n * An iterator that should yield all its values before the main program can\n * continue.\n *\n * @private\n * @type {?Iterator}\n */\n this.yieldAllIterator_ = null;\n\n /**\n * The value that will be sent to the program as the result of suspended\n * yield expression.\n *\n * @type {?}\n */\n this.yieldResult = undefined;\n\n /**\n * The next address where the state machine execution should be resumed.\n *\n *

Program execution starts at 1 and ends at 0.\n *\n * @type {number}\n */\n this.nextAddress = 1;\n\n /**\n * The address that should be executed once an exception is thrown.\n *\n *

Value of 0 means no catch block exist that would handles an exception.\n *\n * @private\n * @type {number}\n */\n this.catchAddress_ = 0;\n\n /**\n * The address that should be executed once the result is being returned\n * or if the exception is thrown and there is no catchAddress specified.\n *\n *

Value of 0 means no finally block is set.\n *\n * @private\n * @type {number}\n */\n this.finallyAddress_ = 0;\n\n /**\n * Stores information for the runtime propagation of values and control\n * flow such as the behaviour of statements (break, continue, return and\n * throw) that perform nonlocal transfers of control.\n *\n * @private\n * @type {null|{return: VALUE}|{exception, isException: boolean}|{jumpTo: number}}.\n */\n this.abruptCompletion_ = null;\n\n /**\n * The preserved abruptCompletion_ when entering a `finally` block. If\n * the `finally` block completes normally the preserved abruptCompletion_ is\n * restored:\n *

\n   * try {\n   * } finally {  // nesting level 0\n   *   // abruptCompletion_ is saved in finallyContexts_[0]\n   *   try {\n   *   } finally {  // nesting level 1\n   *     // abruptCompletion_ is saved in finallyContexts_[1]\n   *     ...\n   *     // abruptCompletion_ is restored from finallyContexts_[1]\n   *   }\n   *   // abruptCompletion_ is restored from finallyContexts_[0]\n   * }\n   * 
\n   *\n   * @private\n   * @type {?Array}.\n   */\n  this.finallyContexts_ = null;\n};\n\n/**\n * Marks generator program as being run.\n *\n * @private\n * @final\n * @return {void}\n * @throws {TypeError} if generator is already running.\n */\n$jscomp.generator.Context.prototype.start_ = function() {\n  if (this.isRunning_) {\n    throw new TypeError('Generator is already running');\n  }\n  this.isRunning_ = true;\n};\n\n/**\n *\n *\n * @private\n * @final\n * @return {void}\n */\n$jscomp.generator.Context.prototype.stop_ = function() {\n  this.isRunning_ = false;\n};\n\n/**\n * Transfers program execution to an appropriate catch/finally block that\n * should be executed if exception occurs.\n *\n * @private\n * @final\n * @return {void}\n */\n$jscomp.generator.Context.prototype.jumpToErrorHandler_ = function() {\n  this.nextAddress = this.catchAddress_ || this.finallyAddress_;\n};\n\n/**\n * Sets the result of suspended yield expression.\n *\n * @private\n * @final\n * @param {?=} value The value to send to the generator.\n * @return {void}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.prototype.next_ = function(value) {\n  this.yieldResult = value;\n};\n\n/**\n * Throws exception as the result of suspended yield.\n *\n * @private\n * @final\n * @param {?} e\n * @return {void}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.prototype.throw_ = function(e) {\n  this.abruptCompletion_ = {exception: e, isException: true};\n  this.jumpToErrorHandler_();\n};\n\n/**\n * Returns a value as the result of generator function.\n *\n * @final\n * @param {VALUE=} value\n * @return {void}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.prototype.return = function(value) {\n  this.abruptCompletion_ = {return: /** @type {VALUE} */ (value)};\n  this.nextAddress = this.finallyAddress_;\n};\n\n/**\n * Changes the context so the program execution will continue from the given\n * state after executing nessesary pending finally blocks first.\n *\n * @final\n * @param {number} nextAddress The state that should be run.\n * @return {void}\n */\n$jscomp.generator.Context.prototype.jumpThroughFinallyBlocks = function(\n    nextAddress) {\n  this.abruptCompletion_ = {jumpTo: nextAddress};\n  this.nextAddress = this.finallyAddress_;\n};\n\n/**\n * Pauses the state machine program assosiated with generator function to yield\n * a value.\n *\n * @final\n * @param {VALUE} value The value to return from the generator function via\n *     the iterator protocol.\n * @param {number} resumeAddress The address where the program should resume.\n * @return {{value: VALUE}}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.prototype.yield = function(value, resumeAddress) {\n  this.nextAddress = resumeAddress;\n  return {value: value};\n};\n\n/**\n * Causes the state machine program to yield all values from an iterator.\n *\n * @final\n * @param {string|!Iterator|!Iterable|!Arguments} iterable\n *     Iterator to yeild all values from.\n * @param {number} resumeAddress The address where the program should resume.\n * @return {void | {value: VALUE}}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.prototype.yieldAll = function(\n    iterable, resumeAddress) {\n  /** @const @type {!Iterator} */ var iterator =\n      $jscomp.makeIterator(iterable);\n  /** @const */ var result = iterator.next();\n  $jscomp.generator.ensureIteratorResultIsObject_(result);\n  if (result.done) {\n    // If `someGenerator` in `x = yield *someGenerator` completes immediately,\n    // x is the return value of that generator.\n    this.yieldResult = result.value;\n    this.nextAddress = resumeAddress;\n    return;\n  }\n  this.yieldAllIterator_ = iterator;\n  return this.yield(result.value, resumeAddress);\n};\n\n/**\n * Changes the context so the program execution will continue from the given\n * state.\n *\n * @final\n * @param {number} nextAddress The state the program should continue\n * @return {void}\n */\n$jscomp.generator.Context.prototype.jumpTo = function(nextAddress) {\n  this.nextAddress = nextAddress;\n};\n\n/**\n * Changes the context so the program execution ends.\n *\n * @final\n * @return {void}\n */\n$jscomp.generator.Context.prototype.jumpToEnd = function() {\n  this.nextAddress = 0;\n};\n\n/**\n * Sets catch / finally handlers.\n * Used for try statements with catch blocks.\n *\n * @final\n * @param {number} catchAddress The address of the catch block.\n * @param {number=} finallyAddress The address of the finally block.\n * @return {void}\n */\n$jscomp.generator.Context.prototype.setCatchFinallyBlocks = function(\n    catchAddress, finallyAddress) {\n  this.catchAddress_ = catchAddress;\n  if (finallyAddress != undefined) {\n    this.finallyAddress_ = finallyAddress;\n  }\n};\n\n/**\n * Sets finally handler.\n * Used for try statements without catch blocks.\n *\n * @const\n * @param {number=} finallyAddress The address of the finally block or 0.\n * @return {void}\n */\n$jscomp.generator.Context.prototype.setFinallyBlock = function(finallyAddress) {\n  this.catchAddress_ = 0;\n  this.finallyAddress_ = finallyAddress || 0;\n};\n\n/**\n * Sets a catch handler and jumps to the next address.\n * Used for try statements without finally blocks.\n *\n * @final\n * @param {number} nextAddress The state that should be run next.\n * @param {number=} catchAddress The address of the catch block or 0.\n * @return {void}\n */\n$jscomp.generator.Context.prototype.leaveTryBlock = function(\n    nextAddress, catchAddress) {\n  this.nextAddress = nextAddress;\n  this.catchAddress_ = catchAddress || 0;\n};\n\n/**\n * Initializes exception variable in the beginning of catch block.\n *\n * @final\n * @param {number=} nextCatchBlockAddress The address of the next catch block\n *     that is preceded by no finally blocks.\n * @return {?} Returns an exception that was thrown from \"try\" block.\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.prototype.enterCatchBlock = function(\n    nextCatchBlockAddress) {\n  this.catchAddress_ = nextCatchBlockAddress || 0;\n  /** @const */ var exception =\n      /** @type {{exception, isException: boolean}} */ (this.abruptCompletion_)\n          .exception;\n  this.abruptCompletion_ = null;\n  return exception;\n};\n\n/**\n * Saves the current throw context which will be restored at the end of finally\n * block.\n *\n * @final\n * @param {number=} nextCatchAddress\n * @param {number=} nextFinallyAddress\n * @param {number=} finallyDepth The nesting level of current \"finally\" block.\n * @return {void}\n */\n$jscomp.generator.Context.prototype.enterFinallyBlock = function(\n    nextCatchAddress, nextFinallyAddress, finallyDepth) {\n  if (!finallyDepth) {\n    this.finallyContexts_ = [this.abruptCompletion_];\n  } else {\n    /**\n     * @type {!Array}\n     */\n    (this.finallyContexts_)[finallyDepth] = this.abruptCompletion_;\n  }\n  this.catchAddress_ = nextCatchAddress || 0;\n  this.finallyAddress_ = nextFinallyAddress || 0;\n};\n\n/**\n * Figures out whether the program execution should continue normally, or jump\n * to the closest catch/finally block.\n *\n * @final\n * @param {number} nextAddress The state that should be run next.\n * @param {number=} finallyDepth The nesting level of current \"finally\" block.\n * @return {void}\n * @suppress {strictMissingProperties}\n */\n$jscomp.generator.Context.prototype.leaveFinallyBlock = function(\n    nextAddress, finallyDepth) {\n  // There could be trailing finally contexts if a nested finally throws an\n  // exception or return.\n  // e.g.\n  // try {\n  //   ...\n  //   return 1;\n  // } finally {\n  //   // finallyDepth == 0\n  //   // finallyContext == [{return: 1}]\n  //   try {\n  //     ...\n  //     try {\n  //       throw new Error(2);\n  //     } finally {\n  //       // finallyDepth == 1\n  //       // finallyContext == [{return: 1}, {exception: Error(2)}]\n  //       try {\n  //         throw new Error(3);\n  //       } finally {\n  //         // finallyDepth == 2\n  //         // finallyContext == [\n  //         //     {return: 1},\n  //         //     {exception: Error(2)},\n  //         //     {exception: Error(3)}\n  //         // ]\n  //         throw new Error(4); // gets written in abruptCompletion_\n  //         // leaveFinallyBlock() never gets called here\n  //       }\n  //       // leaveFinallyBlock() never gets called here\n  //     }\n  //   } catch (e) {\n  //      // swallow error\n  //      // abruptCompletion becomes null\n  //   } finally {\n  //     // finallyDepth == 1\n  //     // finallyContext == [\n  //     //     {return: 1},\n  //     //     null, // overwritten, because catch swallowed the error\n  //     //     {exception: Error(3)}  // left over\n  //     // ]\n  //     // leaveFinallyBlock() called here\n  //     // finallyContext == [{return: 1}]\n  //     // abruptCompletion == null\n  //   }\n  //   // leaveFinallyBlock() called here\n  //   // finallyContext = []\n  //   // abruptCompletion == {return: 1};\n  // }\n  /** @const */ var preservedContext =\n      /**\n       * @type {!Array}\n       */\n      (this.finallyContexts_).splice(finallyDepth || 0)[0];\n  /** @const */ var abruptCompletion = this.abruptCompletion_ =\n      this.abruptCompletion_ || preservedContext;\n  if (abruptCompletion) {\n    if (abruptCompletion.isException) {\n      return this.jumpToErrorHandler_();\n    }\n    // Check if there is a pending break/continue jump that is not preceded by\n    // finally blocks that should be executed before.\n    // We always generate case numbers for the start and end of loops before\n    // numbers for anything they contain, so any finally blocks within will be\n    // guaranteed to have higher addresses than the loop break and continue\n    // positions.\n    // e.g.\n    // l1: while (...) {            // generated addresses: 100: break l1;\n    //       try {                  // generated addresses: 101: finally,\n    //         try {                // generated addresses: 102: finally,\n    //           l2: while (...) {  // generated addresses: 103: break l2;\n    //\n    //                 if (...) {\n    //                   break l1;  // becomes\n    //                              // $context.jumpThroughFinallyBlocks(101),\n    //                              // since 2 finally blocks must be crossed\n    //                 }\n    //                 break l2;    // becomes $context.jumpTo(103)\n    //               }\n    //         } finally {\n    //           // When leaving this finally block:\n    //           // 1. We keep the abrupt completion indicating 'break l1'\n    //           // 2. We jump to the enclosing finally block.\n    //         }\n    //       } finally {\n    //         // When leaving this finally block:\n    //         // 1. We complete the abruptCompletion indicating 'break l1' by\n    //         //   jumping to the loop start address.\n    //         // 2. Abrupt completion is now null, so normal execution\n    //         //   continues from there.\n    //       }\n    //     }\n    if (abruptCompletion.jumpTo != undefined &&\n        this.finallyAddress_ < abruptCompletion.jumpTo) {\n      this.nextAddress = abruptCompletion.jumpTo;\n      this.abruptCompletion_ = null;\n    } else {\n      this.nextAddress = this.finallyAddress_;\n    }\n  } else {\n    this.nextAddress = nextAddress;\n  }\n};\n\n/**\n * Is used in transpilation of `for in` statements.\n *\n * 

for (var i in obj) {...} becomes:\n *

\n * for (var i, $for$in = context$.forIn(obj);\n *      (i = $for$in.getNext()) != null;\n *      ) {\n *   ...\n * }\n * 
\n *\n * @final\n * @param {?} object\n * @return {!$jscomp.generator.Context.PropertyIterator}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.prototype.forIn = function(object) {\n return new $jscomp.generator.Context.PropertyIterator(object);\n};\n\n/**\n * @constructor\n * @final\n * @struct\n * @param {?} object\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.PropertyIterator = function(object) {\n /**\n * @private\n * @const\n * @type {?}\n */\n this.object_ = object;\n\n /**\n * @private\n * @const\n * @type {!Array}\n */\n this.properties_ = [];\n\n for (var property in /** @type {!Object} */ (object)) {\n this.properties_.push(property);\n }\n this.properties_.reverse();\n};\n\n/**\n * Returns the next object's property that is still valid.\n *\n * @final\n * @return {?string}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Context.PropertyIterator.prototype.getNext = function() {\n // The JS spec does not require that properties added after the loop begins\n // be included in the loop, but it does require that the current property\n // must still exist on the object when the loop iteration starts.\n while (this.properties_.length > 0) {\n /** @const */ var property = this.properties_.pop();\n if (property in /** @type {!Object} */ (this.object_)) {\n return property;\n }\n }\n return null;\n};\n\n/**\n * Engine handling execution of a state machine associated with the generator\n * program and its context.\n *\n * @private\n * @template VALUE\n * @constructor\n * @final\n * @struct\n * @param {function(!$jscomp.generator.Context): (void|{value: VALUE})} program\n */\n$jscomp.generator.Engine_ = function(program) {\n /**\n * @private\n * @const\n * @type {!$jscomp.generator.Context}\n */\n this.context_ = new $jscomp.generator.Context();\n\n /**\n * @private\n * @const\n * @type {function(!$jscomp.generator.Context): (void|{value: VALUE})}\n */\n this.program_ = program;\n};\n\n/**\n * Returns an object with two properties done and value.\n * You can also provide a parameter to the next method to send a value to the\n * generator.\n *\n * @private\n * @final\n * @param {?=} value The value to send to the generator.\n * @return {!IIterableResult}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Engine_.prototype.next_ = function(value) {\n this.context_.start_();\n if (this.context_.yieldAllIterator_) {\n return this.yieldAllStep_(\n this.context_.yieldAllIterator_.next, value, this.context_.next_);\n }\n this.context_.next_(value);\n return this.nextStep_();\n};\n\n/**\n * Attempts to finish the generator with a given value.\n *\n * @private\n * @final\n * @param {VALUE} value The value to return.\n * @return {!IIterableResult}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Engine_.prototype.return_ = function(value) {\n this.context_.start_();\n /** @const */ var yieldAllIterator = this.context_.yieldAllIterator_;\n if (yieldAllIterator) {\n /** @const @type {function(VALUE): !IIterableResult} */ var\n returnFunction =\n 'return' in yieldAllIterator ? yieldAllIterator['return'] :\n function(v) {\n return {value: v, done: true};\n };\n return this.yieldAllStep_(returnFunction, value, this.context_.return);\n }\n this.context_.return(value);\n return this.nextStep_();\n};\n\n/**\n * Resumes the execution of a generator by throwing an error into it and\n * returns an object with two properties done and value.\n *\n * @private\n * @final\n * @param {?} exception The exception to throw.\n * @return {!IIterableResult}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Engine_.prototype.throw_ = function(exception) {\n this.context_.start_();\n if (this.context_.yieldAllIterator_) {\n return this.yieldAllStep_(\n this.context_.yieldAllIterator_['throw'], exception,\n this.context_.next_);\n }\n this.context_.throw_(exception);\n return this.nextStep_();\n};\n\n/**\n * Redirects next/throw/return method calls to an iterator passed to \"yield *\".\n *\n * @private\n * @final\n * @template T\n * @param {function(this:Iterator, T): !IIterableResult} action\n * @param {T} value\n * @param {function(this:$jscomp.generator.Context, VALUE): void} nextAction\n * @return {!IIterableResult}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Engine_.prototype.yieldAllStep_ = function(\n action, value, nextAction) {\n try {\n /** @const */ var result = action.call(\n /** @type {!Iterator} */ (this.context_.yieldAllIterator_),\n value);\n $jscomp.generator.ensureIteratorResultIsObject_(result);\n if (!result.done) {\n this.context_.stop_();\n return result;\n }\n // After `x = yield *someGenerator()` x is the return value of the\n // generator, not a value passed to this generator by the next() method.\n /** @const */ var resultValue = result.value;\n } catch (e) {\n this.context_.yieldAllIterator_ = null;\n this.context_.throw_(e);\n return this.nextStep_();\n }\n this.context_.yieldAllIterator_ = null;\n nextAction.call(this.context_, resultValue);\n return this.nextStep_();\n};\n\n/**\n * Continues/resumes program execution until the next suspension point (yield).\n *\n * @private\n * @final\n * @return {!IIterableResult}\n * @suppress {reportUnknownTypes, strictMissingProperties}\n */\n$jscomp.generator.Engine_.prototype.nextStep_ = function() {\n while (this.context_.nextAddress) {\n try {\n /** @const */ var yieldValue = this.program_(this.context_);\n if (yieldValue) {\n this.context_.stop_();\n return {value: yieldValue.value, done: false};\n }\n } catch (e) {\n this.context_.yieldResult = undefined;\n this.context_.throw_(e);\n }\n }\n\n this.context_.stop_();\n if (this.context_.abruptCompletion_) {\n /** @const */ var abruptCompletion = this.context_.abruptCompletion_;\n this.context_.abruptCompletion_ = null;\n if (abruptCompletion.isException) {\n throw abruptCompletion.exception;\n }\n return {value: abruptCompletion.return, done: true};\n }\n return {value: /** @type {?} */ (undefined), done: true};\n};\n\n/**\n * The Generator object that is returned by a generator function and it\n * conforms to both the iterable protocol and the iterator protocol.\n *\n * @private\n * @template VALUE\n * @constructor\n * @final\n * @implements {Generator}\n * @param {!$jscomp.generator.Engine_} engine\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.Generator_ = function(engine) {\n /** @const @override */\n this.next = function(opt_value) {\n return engine.next_(opt_value);\n };\n\n /** @const @override */\n this.throw = function(exception) {\n return engine.throw_(exception);\n };\n\n /** @const @override */\n this.return = function(value) {\n return engine.return_(value);\n };\n\n /** @this {$jscomp.generator.Generator_} */\n this[Symbol.iterator] = function() {\n return this;\n };\n\n // TODO(skill): uncomment once Symbol.toStringTag is polyfilled:\n // this[Symbol.toStringTag] = 'Generator';\n};\n\n/**\n * Creates a generator backed up by Engine running a given program.\n *\n * @final\n * @template VALUE\n * @param {function(this:?, ...): (!Iterator|!Iterable)} generator\n * @param {function(!$jscomp.generator.Context): (void|{value: VALUE})} program\n * @return {!Generator}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.generator.createGenerator = function(generator, program) {\n /** @const */ var result =\n new $jscomp.generator.Generator_(new $jscomp.generator.Engine_(program));\n // The spec says that `myGenFunc() instanceof myGenFunc` must be true.\n // We'll make this work by setting the prototype before calling the\n // constructor every time. All of the methods of the object are defined on the\n // instance by the constructor, so this does no harm.\n // We also cast Generator_ to Object to hide dynamic inheritance from\n // jscompiler, it makes ConformanceRules$BanUnknownThis happy.\n // In some transpiled cases there may not be an explicit prototype, in which\n // case we skip this step.\n if ($jscomp.setPrototypeOf && generator.prototype) {\n /** @type {function(!Object, ?Object): !Object} */ ($jscomp.setPrototypeOf)(\n result, generator.prototype);\n }\n return result;\n};\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Runtime logic for transpiled async functions.\n * @suppress {uselessCode}\n */\n'require base';\n'require es6/generator_engine';\n\n/**\n * Handles the execution of an async function.\n *\n * An async function, foo(a, b), will be rewritten as:\n *\n * ```\n * function foo(a, b) {\n * let $jscomp$async$this = this;\n * let $jscomp$async$arguments = arguments;\n * let $jscomp$async$super$get$x = () => super.x;\n * function* $jscomp$async$generator() {\n * // original body of foo() with:\n * // - await (x) replaced with yield (x)\n * // - arguments replaced with $jscomp$async$arguments\n * // - this replaced with $jscomp$async$this\n * // - super.x replaced with $jscomp$async$super$get$x()\n * // - super.x(5) replaced with $jscomp$async$super$get$x()\n * // .call($jscomp$async$this, 5)\n * }\n * return $jscomp.executeAsyncGenerator($jscomp$async$generator());\n * }\n * ```\n * @param {!Generator} generator\n * @return {!Promise}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.asyncExecutePromiseGenerator = function(generator) {\n function passValueToGenerator(value) {\n return generator.next(value);\n }\n\n function passErrorToGenerator(error) {\n return generator.throw(error);\n }\n\n return new Promise(function(resolve, reject) {\n function handleGeneratorRecord(/** !IIterableResult<*> */ genRec) {\n if (genRec.done) {\n resolve(genRec.value);\n } else {\n // One can await a non-promise, so genRec.value\n // might not already be a promise.\n Promise.resolve(genRec.value)\n .then(passValueToGenerator, passErrorToGenerator)\n .then(handleGeneratorRecord, reject);\n }\n }\n\n handleGeneratorRecord(generator.next());\n });\n};\n\n/**\n * Handles the execution of a generator function returning promises.\n *\n * An async function, foo(a, b), will be rewritten as:\n *\n * ```\n * function foo(a, b) {\n * let $jscomp$async$this = this;\n * let $jscomp$async$arguments = arguments;\n * let $jscomp$async$super$get$x = () => super.x;\n * return $jscomp.asyncExecutePromiseGeneratorFunction(\n * function* () {\n * // original body of foo() with:\n * // - await (x) replaced with yield (x)\n * // - arguments replaced with $jscomp$async$arguments\n * // - this replaced with $jscomp$async$this\n * // - super.x replaced with $jscomp$async$super$get$x()\n * // - super.x(5) replaced with $jscomp$async$super$get$x()\n * // .call($jscomp$async$this, 5)\n * });\n * }\n * ```\n * @param {function(): !Generator} generatorFunction\n * @return {!Promise}\n * @suppress {reportUnknownTypes}\n */\n$jscomp.asyncExecutePromiseGeneratorFunction = function(generatorFunction) {\n return $jscomp.asyncExecutePromiseGenerator(generatorFunction());\n};\n\n/**\n * Handles the execution of a state machine program that represents transpiled\n * async function.\n *\n * @final\n * @param {function(!$jscomp.generator.Context): (void|{value: ?})} program\n * @return {!Promise}\n * @suppress {reportUnknownTypes, visibility}\n */\n$jscomp.asyncExecutePromiseGeneratorProgram = function(program) {\n return $jscomp.asyncExecutePromiseGenerator(\n new $jscomp.generator.Generator_(\n new $jscomp.generator.Engine_(\n program)));\n};\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Symbol polyfill.\n * @suppress {uselessCode}\n */\n\n'require es6/util/arrayiterator';\n'require util/defineproperty';\n'require util/global';\n'require util/polyfill';\n\n/**\n * Initializes the Symbol function.\n * @noinline\n */\n// TODO(rishipal): Remove this function\n$jscomp.initSymbol = function() {};\n\n$jscomp.polyfill('Symbol', function(orig) {\n if (orig) return orig; // no polyfill needed\n\n /**\n * @struct @constructor\n * @param {string} id\n * @param {string=} opt_description\n */\n var SymbolClass = function(id, opt_description) {\n /** @private @const {string} */\n this.$jscomp$symbol$id_ = id;\n\n /** @const {string|undefined} */\n this.description;\n\n // description is read-only.\n $jscomp.defineProperty(\n this, 'description',\n {configurable: true, writable: true, value: opt_description});\n };\n\n\n /** @override */\n SymbolClass.prototype.toString = function() {\n return this.$jscomp$symbol$id_;\n };\n\n\n /** @const {string} */\n var SYMBOL_PREFIX = 'jscomp_symbol_';\n\n var counter = 0;\n\n /**\n * Produces \"symbols\" (actually just unique strings).\n * @param {string=} opt_description\n * @return {!SymbolClass}\n * @this {?Object}\n */\n var symbolPolyfill = function(opt_description) {\n if (this instanceof symbolPolyfill) {\n throw new TypeError('Symbol is not a constructor');\n }\n return (new SymbolClass(\n SYMBOL_PREFIX + (opt_description || '') + '_' + (counter++),\n opt_description));\n };\n\n return symbolPolyfill;\n}, 'es6', 'es3');\n\n$jscomp.polyfill('Symbol.iterator', function(orig) {\n if (orig) return orig; // no polyfill needed\n\n var symbolIterator = Symbol('Symbol.iterator');\n\n // Polyfill 'Symbol.iterator' onto Array and the various TypedArray* objects.\n // This array uses strings to index into $jscomp.global because the TypedArray\n // objects are present in IE11 but not on older browsers. Using bracket access\n // saves code size compared to `typeof Int8Array === 'function' && Int8Array`.\n var /** !Array */ arrayLikes = [\n 'Array',\n // List taken from https://tc39.es/ecma262/#sec-typedarray-objects.\n // The BigInt*Arrays are intentionally omitted because they are only present\n // in browsers where Symbol is fully supported.\n 'Int8Array', 'Uint8Array', 'Uint8ClampedArray', 'Int16Array', 'Uint16Array',\n 'Int32Array', 'Uint32Array', 'Float32Array', 'Float64Array'\n ];\n\n for (var i = 0; i < arrayLikes.length; i++) {\n var ArrayLikeCtor = /** @type {*} */ ($jscomp.global[arrayLikes[i]]);\n if (typeof ArrayLikeCtor === 'function' &&\n typeof ArrayLikeCtor.prototype[symbolIterator] != 'function') {\n $jscomp.defineProperty(ArrayLikeCtor.prototype, symbolIterator, {\n configurable: true,\n writable: true,\n /**\n * @this {IArrayLike}\n * @return {!IteratorIterable}\n */\n value: function() {\n return $jscomp.iteratorPrototype($jscomp.arrayIteratorImpl(this));\n }\n });\n }\n }\n return symbolIterator;\n}, 'es6', 'es3');\n\n$jscomp.polyfill('Symbol.asyncIterator', function(orig) {\n if (orig) {\n return orig;\n }\n return Symbol('Symbol.asyncIterator');\n}, 'es9', 'es3');\n\n/**\n * Returns an iterator with the given `next` method. Passing\n * all iterators through this function allows easily extending\n * the definition of `%IteratorPrototype%` if methods are ever\n * added to it in the future.\n *\n * @param {function(this: Iterator): T} next\n * @return {!IteratorIterable}\n * @template T\n */\n$jscomp.iteratorPrototype = function(next) {\n var iterator = {next: next};\n /**\n * @this {IteratorIterable}\n * @return {!IteratorIterable}\n */\n iterator[Symbol.iterator] = function() {\n return this;\n };\n return /** @type {!IteratorIterable} */ (iterator);\n};\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require base';\n'require es6/util/makeiterator';\n'require util/defines';\n'require util/global';\n'require util/polyfill';\n\n\n$jscomp.polyfill('Promise',\n /**\n * @param {*} NativePromise\n * @return {*}\n * @suppress {reportUnknownTypes}\n */\n function(NativePromise) {\n function platformSupportsPromiseRejectionEvents() {\n return typeof $jscomp.global['PromiseRejectionEvent'] !== 'undefined';\n }\n\n function globalPromiseIsNative() {\n return $jscomp.global['Promise'] &&\n $jscomp.global['Promise'].toString().indexOf('[native code]') !== -1;\n }\n\n function shouldForcePolyfillPromise() {\n // Only force polyfill if the global promise is native.\n return ($jscomp.FORCE_POLYFILL_PROMISE ||\n $jscomp.FORCE_POLYFILL_PROMISE_WHEN_NO_UNHANDLED_REJECTION &&\n !platformSupportsPromiseRejectionEvents()) && globalPromiseIsNative();\n }\n\n // TODO(bradfordcsmith): Do we need to add checks for standards conformance?\n // e.g. The version of FireFox we currently use for testing has a Promise\n // that fails to reject attempts to fulfill it with itself, but that\n // isn't reasonably testable here.\n if (NativePromise && !shouldForcePolyfillPromise()) {\n return NativePromise;\n }\n\n /**\n * Schedules code to be executed asynchronously.\n * @constructor\n * @struct\n */\n function AsyncExecutor() {\n /**\n * Batch of functions to execute.\n *\n * Will be `null` initially and immediately after a batch finishes\n * executing.\n * @private {?Array}\n */\n this.batch_ = null;\n }\n\n /**\n * Schedule a function to execute asynchronously.\n *\n * - The function will execute:\n * - After the current call stack has completed executing.\n * - After any functions previously scheduled using this object.\n * - The return value will be ignored.\n * - An exception thrown by the method will be caught and asynchronously\n * rethrown when it cannot interrupt any other code. This class provides\n * no way to catch such exceptions.\n * @param {function():?} f\n */\n AsyncExecutor.prototype.asyncExecute = function(f) {\n if (this.batch_ == null) {\n // no batch created yet, or last batch was fully executed\n this.batch_ = [];\n var self = this;\n this.asyncExecuteFunction(function() { self.executeBatch_(); });\n }\n this.batch_.push(f);\n };\n\n // NOTE: We want to make sure AsyncExecutor will work as expected even if\n // testing code should override setTimeout()\n /** @const {function(!Function, number)} */\n var nativeSetTimeout = $jscomp.global['setTimeout'];\n\n /**\n * Schedule a function to execute asynchronously as soon as possible.\n *\n * NOTE: May be overridden for testing.\n * @package\n * @param {function()} f\n */\n AsyncExecutor.prototype.asyncExecuteFunction = function(f) {\n nativeSetTimeout(f, 0);\n };\n\n /**\n * Execute scheduled jobs in a batch until all are executed or the batch\n * execution time limit has been reached.\n * @private\n */\n AsyncExecutor.prototype.executeBatch_ = function() {\n while (this.batch_ && this.batch_.length) {\n var /** !Array */ executingBatch = this.batch_;\n // Executions scheduled while executing this batch go into a new one to\n // avoid the batch array getting too big.\n this.batch_ = [];\n for (var i = 0; i < executingBatch.length; ++i) {\n var f = /** @type {function()} */ (executingBatch[i]);\n executingBatch[i] = null; // free memory\n try {\n f();\n } catch (error) {\n this.asyncThrow_(error);\n }\n }\n }\n // All jobs finished executing, so force scheduling a new batch next\n // time asyncExecute() is called.\n this.batch_ = null;\n };\n\n /**\n * @private\n * @param {*} exception\n */\n AsyncExecutor.prototype.asyncThrow_ = function(exception) {\n this.asyncExecuteFunction(function() { throw exception; });\n };\n\n /**\n * @enum {number}\n */\n var PromiseState = {\n /** The Promise is waiting for resolution. */\n PENDING: 0,\n\n /** The Promise has been resolved with a fulfillment value. */\n FULFILLED: 1,\n\n /** The Promise has been resolved with a rejection reason. */\n REJECTED: 2\n };\n\n\n /**\n * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise\n * @param {function(\n * function((TYPE|IThenable|Thenable|null)=),\n * function(*=))} executor\n * @constructor\n * @extends {Promise}\n * @template TYPE\n */\n var PolyfillPromise = function(executor) {\n /** @private {PromiseState} */\n this.state_ = PromiseState.PENDING;\n\n /**\n * The settled result of the Promise. Immutable once set with either a\n * fulfillment value or rejection reason.\n * @private {*}\n */\n this.result_ = undefined;\n\n /**\n * These functions must be asynchronously executed when this promise\n * settles.\n * @private {?Array}\n */\n this.onSettledCallbacks_ = [];\n\n /**\n * Whether the rejection has any handler when the promise is rejected.\n * @private {boolean}\n */\n this.isRejectionHandled_ = false;\n\n var resolveAndReject = this.createResolveAndReject_();\n try {\n executor(resolveAndReject.resolve, resolveAndReject.reject);\n } catch (e) {\n resolveAndReject.reject(e);\n }\n };\n\n\n /**\n * Create a pair of functions for resolving or rejecting this Promise.\n *\n *

After the resolve or reject function has been called once, later calls\n * do nothing.\n * @private\n * @return {{\n * resolve: function((TYPE|IThenable|Thenable|null)=),\n * reject: function(*=)\n * }}\n */\n PolyfillPromise.prototype.createResolveAndReject_ = function() {\n var thisPromise = this;\n var alreadyCalled = false;\n /**\n * @param {function(this:PolyfillPromise, T=)} method\n * @return {function(T=)}\n * @template T\n */\n function firstCallWins(method) {\n return function(/** T= */ x) {\n if (!alreadyCalled) {\n alreadyCalled = true;\n method.call(thisPromise, x);\n }\n };\n }\n return {\n resolve: firstCallWins(this.resolveTo_),\n reject: firstCallWins(this.reject_)\n };\n };\n\n\n /**\n * @private\n * @param {*=} value\n */\n PolyfillPromise.prototype.resolveTo_ = function(value) {\n if (value === this) {\n this.reject_(new TypeError('A Promise cannot resolve to itself'));\n } else if (value instanceof PolyfillPromise) {\n this.settleSameAsPromise_(/** @type {!PolyfillPromise} */ (value));\n } else if (isObject(value)) {\n this.resolveToNonPromiseObj_(/** @type {!Object} */ (value));\n } else {\n this.fulfill_(value);\n }\n };\n\n\n /**\n * @private\n * @param {!Object} obj\n * @suppress {strictMissingProperties} obj.then\n */\n PolyfillPromise.prototype.resolveToNonPromiseObj_ = function(obj) {\n var thenMethod = undefined;\n\n try {\n thenMethod = obj.then;\n } catch (error) {\n this.reject_(error);\n return;\n }\n if (typeof thenMethod == 'function') {\n this.settleSameAsThenable_(thenMethod, /** @type {!Thenable} */ (obj));\n } else {\n this.fulfill_(obj);\n }\n };\n\n\n /**\n * @param {*} value anything\n * @return {boolean}\n */\n function isObject(value) {\n switch (typeof value) {\n case 'object':\n return value != null;\n case 'function':\n return true;\n default:\n return false;\n }\n }\n\n /**\n * Reject this promise for the given reason.\n * @private\n * @param {*=} reason\n * @throws {!Error} if this promise is already fulfilled or rejected.\n */\n PolyfillPromise.prototype.reject_ = function(reason) {\n this.settle_(PromiseState.REJECTED, reason);\n };\n\n /**\n * Fulfill this promise with the given value.\n * @private\n * @param {!TYPE} value\n * @throws {!Error} when this promise is already fulfilled or rejected.\n */\n PolyfillPromise.prototype.fulfill_ = function(value) {\n this.settle_(PromiseState.FULFILLED, value);\n };\n\n /**\n * Fulfill or reject this promise with the given value/reason.\n * @private\n * @param {!PromiseState} settledState (FULFILLED or REJECTED)\n * @param {*} valueOrReason\n * @throws {!Error} when this promise is already fulfilled or rejected.\n */\n PolyfillPromise.prototype.settle_ = function(settledState, valueOrReason) {\n if (this.state_ != PromiseState.PENDING) {\n throw new Error(\n 'Cannot settle(' + settledState + ', ' + valueOrReason +\n '): Promise already settled in state' + this.state_);\n }\n this.state_ = settledState;\n this.result_ = valueOrReason;\n if (this.state_ === PromiseState.REJECTED) {\n this.scheduleUnhandledRejectionCheck_();\n }\n this.executeOnSettledCallbacks_();\n };\n\n PolyfillPromise.prototype.scheduleUnhandledRejectionCheck_ = function() {\n var self = this;\n nativeSetTimeout(function() {\n if (self.notifyUnhandledRejection_()) {\n // console may not exist on IE 9.\n var nativeConsole = $jscomp.global['console'];\n if (typeof nativeConsole !== 'undefined') {\n nativeConsole.error(self.result_);\n }\n }\n }, 1);\n };\n\n /**\n * Dispatches `unhandledrejection` event if the rejection is unhandled.\n * @return {boolean} False means the fallback handler does not need to run. It\n * is either because rejection handlers are detected or one of the\n * `unhandledjrection` event handlers call `preventDefault()`.\n * True otherwise.\n * @private\n */\n PolyfillPromise.prototype.notifyUnhandledRejection_ = function() {\n if (this.isRejectionHandled_) {\n return false;\n }\n var NativeCustomEvent = $jscomp.global['CustomEvent'];\n var NativeEvent = $jscomp.global['Event'];\n var nativeDispatchEvent = $jscomp.global['dispatchEvent'];\n if (typeof nativeDispatchEvent === 'undefined') {\n return true;\n }\n\n var event;\n if (typeof NativeCustomEvent === 'function') {\n event =\n new NativeCustomEvent('unhandledrejection', {cancelable: true});\n } else if (typeof NativeEvent === 'function') {\n // CustomEvent is not available in FireFox < 48 in workers.\n // https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent\n event = new NativeEvent('unhandledrejection', {cancelable: true});\n } else {\n // IE does not support CustomEvent constructor.\n event = $jscomp.global['document'].createEvent('CustomEvent');\n event.initCustomEvent(\n 'unhandledrejection', /** canBubbleArg */ false,\n /** cancelableArg */ true, event);\n }\n event.promise = this;\n event.reason = this.result_;\n\n return nativeDispatchEvent(event);\n };\n\n PolyfillPromise.prototype.executeOnSettledCallbacks_ = function() {\n if (this.onSettledCallbacks_ != null) {\n for (var i = 0; i < this.onSettledCallbacks_.length; ++i) {\n asyncExecutor.asyncExecute(this.onSettledCallbacks_[i]);\n }\n this.onSettledCallbacks_ = null; // free memory\n }\n };\n\n /**\n * All promise async execution is managed by a single executor for the\n * sake of efficiency.\n * @const {!AsyncExecutor}\n */\n var asyncExecutor = new AsyncExecutor();\n\n /**\n * Arrange to settle this promise in the same way as the given thenable.\n * @private\n * @param {!PolyfillPromise} promise\n */\n PolyfillPromise.prototype.settleSameAsPromise_ = function(promise) {\n var methods = this.createResolveAndReject_();\n\n // Calling then() would create an unnecessary extra promise.\n promise.callWhenSettled_(methods.resolve, methods.reject);\n };\n\n /**\n * Arrange to settle this promise in the same way as the given thenable.\n * @private\n * @param {function(\n * function((TYPE|IThenable|Thenable|null)=),\n * function(*=))\n * } thenMethod\n * @param {!Thenable} thenable\n */\n PolyfillPromise.prototype.settleSameAsThenable_ = function(\n thenMethod, thenable) {\n var methods = this.createResolveAndReject_();\n\n // Don't trust an unknown thenable implementation not to throw exceptions.\n try {\n thenMethod.call(thenable, methods.resolve, methods.reject);\n } catch (error) {\n methods.reject(error);\n }\n };\n\n /** @override */\n PolyfillPromise.prototype.then = function(onFulfilled, onRejected) {\n var resolveChild;\n var rejectChild;\n var childPromise = new PolyfillPromise(function(resolve, reject) {\n resolveChild = resolve;\n rejectChild = reject;\n });\n function createCallback(paramF, defaultF) {\n // The spec says to ignore non-function values for onFulfilled and\n // onRejected\n if (typeof paramF == 'function') {\n return function(x) {\n try {\n resolveChild(paramF(x));\n } catch (error) {\n rejectChild(error);\n }\n };\n } else {\n return defaultF;\n }\n }\n\n this.callWhenSettled_(\n createCallback(onFulfilled, resolveChild),\n createCallback(onRejected, rejectChild));\n return childPromise;\n };\n\n /** @override */\n PolyfillPromise.prototype.catch = function(onRejected) {\n return this.then(undefined, onRejected);\n };\n\n\n PolyfillPromise.prototype.callWhenSettled_ = function(\n onFulfilled, onRejected) {\n var /** !PolyfillPromise */ thisPromise = this;\n function callback() {\n switch (thisPromise.state_) {\n case PromiseState.FULFILLED:\n onFulfilled(thisPromise.result_);\n break;\n case PromiseState.REJECTED:\n onRejected(thisPromise.result_);\n break;\n default:\n throw new Error('Unexpected state: ' + thisPromise.state_);\n }\n }\n if (this.onSettledCallbacks_ == null) {\n // we've already settled\n asyncExecutor.asyncExecute(callback);\n } else {\n this.onSettledCallbacks_.push(callback);\n }\n this.isRejectionHandled_ = true;\n };\n\n // called locally, so give it a name\n function resolvingPromise(opt_value) {\n if (opt_value instanceof PolyfillPromise) {\n return opt_value;\n } else {\n return new PolyfillPromise(function(resolve, reject) {\n resolve(opt_value);\n });\n }\n }\n PolyfillPromise['resolve'] = resolvingPromise;\n\n\n PolyfillPromise['reject'] = function(opt_reason) {\n return new PolyfillPromise(function(resolve, reject) {\n reject(opt_reason);\n });\n };\n\n\n PolyfillPromise['race'] = function(thenablesOrValues) {\n return new PolyfillPromise(function(resolve, reject) {\n var /** !Iterator<*> */ iterator =\n $jscomp.makeIterator(thenablesOrValues);\n for (var /** !IIterableResult<*> */ iterRec = iterator.next();\n !iterRec.done;\n iterRec = iterator.next()) {\n // Using resolvingPromise() allows us to treat all elements the same\n // way.\n // NOTE: resolvingPromise(promise) always returns the argument\n // unchanged.\n // Using .callWhenSettled_() instead of .then() avoids creating an\n // unnecessary extra promise.\n resolvingPromise(iterRec.value).callWhenSettled_(resolve, reject);\n }\n });\n };\n\n\n PolyfillPromise['all'] = function(thenablesOrValues) {\n var /** !Iterator<*> */ iterator = $jscomp.makeIterator(thenablesOrValues);\n var /** !IIterableResult<*> */ iterRec = iterator.next();\n\n if (iterRec.done) {\n return resolvingPromise([]);\n } else {\n return new PolyfillPromise(function(resolveAll, rejectAll) {\n var resultsArray = [];\n var unresolvedCount = 0;\n\n function onFulfilled(i) {\n return function(ithResult) {\n resultsArray[i] = ithResult;\n unresolvedCount--;\n if (unresolvedCount == 0) {\n resolveAll(resultsArray);\n }\n };\n }\n\n do {\n resultsArray.push(undefined);\n unresolvedCount++;\n // Using resolvingPromise() allows us to treat all elements the same\n // way.\n // NOTE: resolvingPromise(promise) always returns the argument\n // unchanged. Using .callWhenSettled_() instead of .then() avoids\n // creating an unnecessary extra promise.\n resolvingPromise(iterRec.value)\n .callWhenSettled_(\n onFulfilled(resultsArray.length - 1), rejectAll);\n iterRec = iterator.next();\n } while (!iterRec.done);\n });\n }\n };\n\n return PolyfillPromise;\n}, 'es6', 'es3');\n","/*\n * Copyright 2017 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/global';\n\n\n/**\n * @fileoverview Check one of the most obscure features of ES6 as a proxy\n * for full conformance. If this is enabled, this test is used instead of\n * larger, more specific conformance tests.\n */\n\n/**\n * Check ES6 conformance by checking an obscure detail of Proxy that\n * wasn't implemented correctly until after all other ES6 features in\n * most browsers.\n * @return {boolean} Whether Proxy works correctly.\n * @suppress {reportUnknownTypes}\n */\n$jscomp.checkEs6ConformanceViaProxy = function() {\n try {\n var proxied = {};\n var proxy = Object.create(new $jscomp.global['Proxy'](proxied, {\n 'get': function (target, key, receiver) {\n return target == proxied && key == 'q' && receiver == proxy;\n }\n }));\n return proxy['q'] === true;\n } catch (err) {\n return false;\n }\n};\n\n/**\n * If this is true, assume that a runtime which implements Proxy also\n * implements the rest of the ECMAScript 2015 spec.\n * @define {boolean}\n */\n$jscomp.USE_PROXY_FOR_ES6_CONFORMANCE_CHECKS = false;\n\n/**\n * Whether the runtime implements the entire ECMAScript 2015 spec.\n * @const {boolean}\n */\n$jscomp.ES6_CONFORMANCE =\n $jscomp.USE_PROXY_FOR_ES6_CONFORMANCE_CHECKS &&\n $jscomp.checkEs6ConformanceViaProxy();\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require base';\n\n/**\n * Synonym for Object.prototype.hasOwnProperty.call(obj, prop).\n * @param {!Object} obj\n * @param {string} prop\n * @return {boolean}\n */\n$jscomp.owns = function(obj, prop) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n};\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require es6/conformance';\n'require es6/util/makeiterator';\n'require util/defineproperty';\n'require util/defines';\n'require util/owns';\n'require util/polyfill';\n\n$jscomp.polyfill('WeakMap',\n /**\n * @param {*} NativeWeakMap\n * @return {*}\n * @suppress {reportUnknownTypes}\n */\n function(NativeWeakMap) {\n /**\n * Checks conformance of the existing WeakMap.\n * @return {boolean} True if the browser's implementation conforms.\n */\n function isConformant() {\n if (!NativeWeakMap || !Object.seal) return false;\n try {\n var x = Object.seal({});\n var y = Object.seal({});\n var map = new /** @type {function(new: WeakMap, !Array)} */ (\n NativeWeakMap)([[x, 2], [y, 3]]);\n if (map.get(x) != 2 || map.get(y) != 3) return false;\n map.delete(x);\n map.set(y, 4);\n return !map.has(x) && map.get(y) == 4;\n } catch (err) { // This should hopefully never happen, but let's be safe.\n return false;\n }\n }\n if ($jscomp.USE_PROXY_FOR_ES6_CONFORMANCE_CHECKS) {\n if (NativeWeakMap && $jscomp.ES6_CONFORMANCE) return NativeWeakMap;\n } else {\n if (isConformant()) return NativeWeakMap;\n }\n\n var prop = '$jscomp_hidden_' + Math.random();\n\n /** @constructor */\n function WeakMapMembership() {}\n\n /**\n * Returns whether the argument is a valid WeakMap key.\n * @param {*} key\n * @return {boolean}\n */\n function isValidKey(key) {\n var type = typeof key;\n return (type === 'object' && key !== null) || type === 'function';\n }\n\n /**\n * Inserts the hidden property into the target.\n * @param {!Object} target\n */\n function insert(target) {\n if (!$jscomp.owns(target, prop)) {\n var obj = new WeakMapMembership();\n // TODO(sdh): This property will be enumerated in IE8. If this becomes\n // a problem, we could avoid it by copying an infrequently-used non-enum\n // method (like toLocaleString) onto the object itself and encoding the\n // property on the copy instead. This codepath must be easily removable\n // if IE8 support is not needed.\n $jscomp.defineProperty(target, prop, {value: obj});\n }\n }\n\n /**\n * Monkey-patches the freezing methods to ensure that the hidden\n * property is added before any freezing happens.\n * @param {string} name\n */\n function patch(name) {\n if ($jscomp.ISOLATE_POLYFILLS) {\n // Monkey-patching Object.freeze and friends can cause bad interactions\n // with third-party code. This means that polyfill isolation does not\n // support inserting frozen objects as keys into a WeakMap.\n return;\n }\n var prev = Object[name];\n if (prev) {\n Object[name] = function(target) {\n if (target instanceof WeakMapMembership) {\n return target;\n } else {\n if (Object.isExtensible(target)) {\n insert(target);\n }\n return prev(target);\n }\n };\n }\n }\n patch('freeze');\n patch('preventExtensions');\n patch('seal');\n // Note: no need to patch Reflect.preventExtensions since the polyfill\n // just calls Object.preventExtensions anyway (and if it's not polyfilled\n // then neither is WeakMap).\n\n var index = 0;\n\n /**\n * Polyfill for WeakMap:\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap\n *\n * This implementation is as non-leaky as possible, due to patching\n * the freezing and sealing operations. It does not include any logic\n * to handle cases where a key was somehow made non-extensible without\n * the special hidden property being added. It takes some care to ensure\n * the hidden property is not enumerated over nor discoverable, though\n * it's not completely secure (particularly in IE8).\n *\n * @constructor\n * @extends {WeakMap}\n * @template KEY, VALUE\n * @param {!Iterator>|!Array>|null=}\n * opt_iterable Optional initial data.\n */\n var PolyfillWeakMap = function(opt_iterable) {\n /** @private @const {string} */\n this.id_ = (index += (Math.random() + 1)).toString();\n\n if (opt_iterable) {\n var iter = $jscomp.makeIterator(opt_iterable);\n var entry;\n while (!(entry = iter.next()).done) {\n var item = entry.value;\n this.set(/** @type {KEY} */ (item[0]), /** @type {VALUE} */ (item[1]));\n }\n }\n };\n\n /** @override */\n PolyfillWeakMap.prototype.set = function(key, value) {\n if (!isValidKey(key)) {\n throw new Error('Invalid WeakMap key');\n }\n insert(key);\n if (!$jscomp.owns(key, prop)) {\n // NOTE: If the insert() call fails on the key, but the property\n // has previously successfully been added higher up the prototype\n // chain, then we'll silently misbehave. Instead, throw immediately\n // before doing something bad. If this becomes a problem (e.g. due\n // to some rogue frozen objects) then we may need to add a slow and\n // leaky fallback array to each WeakMap instance, as well as extra\n // logic in each accessor to use it (*only*) when necessary.\n throw new Error('WeakMap key fail: ' + key);\n }\n key[prop][this.id_] = value;\n return this;\n };\n\n /** @override */\n PolyfillWeakMap.prototype.get = function(key) {\n return isValidKey(key) && $jscomp.owns(key, prop) ? key[prop][this.id_] :\n undefined;\n };\n\n /** @override */\n PolyfillWeakMap.prototype.has = function(key) {\n return isValidKey(key) && $jscomp.owns(key, prop) &&\n $jscomp.owns(key[prop], this.id_);\n };\n\n /** @override */\n PolyfillWeakMap.prototype.delete = function(key) {\n if (!isValidKey(key) || !$jscomp.owns(key, prop) ||\n !$jscomp.owns(key[prop], this.id_)) {\n return false;\n }\n return delete key[prop][this.id_];\n };\n\n return PolyfillWeakMap;\n}, 'es6', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Utilities for iterator-returning methods.\n */\n'require es6/symbol';\n\n\n/**\n * Creates an iterator from an array-like, with a transformation function.\n * @param {!IArrayLike} array\n * @param {function(number, INPUT): OUTPUT} transform\n * @return {!IteratorIterable}\n * @template INPUT, OUTPUT\n * @suppress {checkTypes|reportUnknownTypes}\n */\n$jscomp.iteratorFromArray = function(array, transform) {\n // NOTE: IE8 doesn't support indexing from boxed Strings.\n if (array instanceof String) array = array + '';\n var i = 0;\n var done = false;\n var iter = {\n next: function() {\n // Once we return done, we must always return done, even if the array\n // grows later.\n if (!done && i < array.length) {\n var index = i++;\n return {value: transform(index, array[index]), done: false};\n }\n done = true;\n return {done: true, value: void 0};\n }\n };\n iter[Symbol.iterator] = function() { return iter; };\n return iter;\n};\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/polyfill';\n'require es6/util/iteratorfromarray';\n\n$jscomp.polyfill('Array.prototype.entries', function(orig) {\n if (orig) return orig;\n\n /**\n * Returns an iterator of [key, value] arrays, one for each entry\n * in the given array.\n *\n * @this {!IArrayLike}\n * @return {!IteratorIterable>}\n * @template VALUE\n * @suppress {reportUnknownTypes}\n */\n var polyfill = function() {\n return $jscomp.iteratorFromArray(\n this, function(i, v) { return [i, v]; });\n };\n\n return polyfill;\n}, 'es6', 'es3');\n","/*\n * Copyright 2018 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/polyfill';\n'require es6/promise/promise';\n\n$jscomp.polyfill('Promise.prototype.finally', function(orig) {\n if (orig) return orig;\n\n /**\n * @this {!Promise}\n * @param {function():?} onFinally\n * @return {!Promise}\n * @template VALUE\n * @suppress {reportUnknownTypes}\n */\n var polyfill = function(onFinally) {\n return this.then(\n function(value) {\n var promise = Promise.resolve(onFinally());\n return promise.then(function () { return value; });\n },\n function(reason) {\n var promise = Promise.resolve(onFinally());\n return promise.then(function () { throw reason; });\n });\n };\n\n return polyfill;\n}, 'es9', 'es3');\n","/*\n * Copyright 2018 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview\n * @suppress {uselessCode}\n */\n'require util/owns';\n'require util/polyfill';\n'require util/shouldpolyfill';\n\n/**\n * Equivalent to the Object.assign() method, but guaranteed to be available for use in code\n * generated by the compiler.\n *\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign\n *\n * Copies values of all enumerable own properties from one or more\n * sources to the given target object, and returns the target.\n *\n * @final\n * @param {!Object} target The target object onto which to copy.\n * @param {...?Object} var_args The source objects.\n * @return {!Object} The target object is returned.\n */\n$jscomp.assign =\n ($jscomp.TRUST_ES6_POLYFILLS && typeof Object.assign == 'function') ?\n Object.assign :\n /**\n * @param {!Object} target\n * @param {...?Object} var_args\n * @return {!Object}\n * @suppress {reportUnknownTypes}\n */\n function(target, var_args) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n if (!source) continue;\n for (var key in source) {\n if ($jscomp.owns(source, key)) target[key] = source[key];\n }\n }\n return target;\n };\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview\n * @suppress {uselessCode}\n */\n'require es6/util/assign';\n'require util/polyfill';\n\n$jscomp.polyfill('Object.assign', function(orig) {\n return orig || $jscomp.assign;\n}, 'es6', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require es6/util/iteratorfromarray';\n'require util/polyfill';\n\n$jscomp.polyfill('Array.prototype.keys', function(orig) {\n if (orig) return orig;\n\n /**\n * Returns an iterator of keys of the given array.\n *\n * @this {!IArrayLike}\n * @return {!IteratorIterable}\n */\n var polyfill = function() {\n return $jscomp.iteratorFromArray(this, function(i) { return i; });\n };\n\n return polyfill;\n}, 'es6', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/polyfill';\n\n$jscomp.polyfill('Object.is', function(orig) {\n if (orig) return orig;\n\n /**\n * Polyfill for Object.is() method:\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n *\n * Determines whether two values are the same value (that is,\n * functionally equivalent). This is the same as ===-equality,\n * except for two cases: 0 is not the same as -0, and NaN is\n * the same as NaN.\n *\n * @param {*} left\n * @param {*} right\n * @return {boolean}\n */\n var polyfill = function(left, right) {\n if (left === right) {\n // Handle the 0 === -0 exception\n return (left !== 0) || (1 / left === 1 / /** @type {number} */ (right));\n } else {\n // Handle the NaN !== NaN exception\n return (left !== left) && (right !== right);\n }\n };\n\n return polyfill;\n}, 'es6', 'es3');\n","/*\n * Copyright 2017 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require es6/object/is';\n'require util/polyfill';\n\n$jscomp.polyfill('Array.prototype.includes', function(orig) {\n if (orig) return orig;\n\n /**\n * Polyfills Array.prototype.includes.\n *\n * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/includes\n *\n * @this {!IArrayLike}\n * @param {T} searchElement\n * @param {number=} opt_fromIndex\n * @return {boolean}\n * @template T\n * @suppress {reportUnknownTypes}\n */\n var includes = function(searchElement, opt_fromIndex) {\n var array = this;\n if (array instanceof String) {\n array = /** @type {!IArrayLike} */ (String(array));\n }\n var len = array.length;\n var i = opt_fromIndex || 0;\n if (i < 0) {\n i = Math.max(i + len, 0);\n }\n for (; i < len; i++) {\n var element = array[i];\n if (element === searchElement || Object.is(element, searchElement)) {\n return true;\n }\n }\n return false;\n };\n\n return includes;\n}, 'es7', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require base';\n\n\n/**\n * Throws if the argument is a RegExp, or if thisArg is undefined.\n * @param {?} thisArg The 'this' arg, which must be defined.\n * @param {*} arg The first argument of the function, which mustn't be a RegExp.\n * @param {string} func Name of the function, for reporting.\n * @return {string} The thisArg, coerced to a string.\n * @suppress {reportUnknownTypes}\n */\n$jscomp.checkStringArgs = function(thisArg, arg, func) {\n if (thisArg == null) {\n throw new TypeError(\n \"The 'this' value for String.prototype.\" + func +\n ' must not be null or undefined');\n }\n if (arg instanceof RegExp) {\n throw new TypeError(\n 'First argument to String.prototype.' + func +\n ' must not be a regular expression');\n }\n return thisArg + '';\n};\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/checkstringargs';\n'require util/polyfill';\n\n$jscomp.polyfill('String.prototype.includes', function(orig) {\n if (orig) return orig;\n\n /**\n * Searches for a substring, starting at the given position.\n *\n *

Polyfills the instance method String.prototype.includes().\n *\n * @this {string}\n * @param {string} searchString\n * @param {number=} opt_position\n * @return {boolean}\n */\n var polyfill = function(searchString, opt_position) {\n 'use strict';\n var string = $jscomp.checkStringArgs(this, searchString, 'includes');\n return string.indexOf(searchString, opt_position || 0) !== -1;\n };\n\n return polyfill;\n}, 'es6', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview Utility for Array methods that find elements.\n */\n'require base';\n\n// TODO(sdh): would be nice to template on the ARRAY type as well,\n// so that the third arg type of callback can be refined to be\n// exactly the same as the array type, but then there's no way to\n// enforce that it must, in fact, be an array.\n/**\n * Internal implementation of find.\n * @param {!IArrayLike} array\n * @param {function(this: THIS, VALUE, number, !IArrayLike): *} callback\n * @param {THIS} thisArg\n * @return {{i: number, v: (VALUE|undefined)}}\n * @template THIS, VALUE\n * @suppress {reportUnknownTypes}\n */\n$jscomp.findInternal = function(array, callback, thisArg) {\n if (array instanceof String) {\n array = /** @type {!IArrayLike} */ (String(array));\n }\n var len = array.length;\n for (var i = 0; i < len; i++) {\n var value = array[i];\n if (callback.call(thisArg, value, i, array)) return {i: i, v: value};\n }\n return {i: -1, v: void 0};\n};\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/findinternal';\n'require util/polyfill';\n\n$jscomp.polyfill('Array.prototype.find', function(orig) {\n if (orig) return orig;\n\n /**\n * Finds and returns an element that satisfies the given predicate.\n *\n * @this {!IArrayLike}\n * @param {function(this: THIS, VALUE, number, !IArrayLike): *}\n * callback\n * @param {THIS=} opt_thisArg\n * @return {VALUE|undefined} The found value, or undefined.\n * @template VALUE, THIS\n * @suppress {reportUnknownTypes}\n */\n var polyfill = function(callback, opt_thisArg) {\n return $jscomp.findInternal(this, callback, opt_thisArg).v;\n };\n\n return polyfill;\n}, 'es6', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/findinternal';\n'require util/polyfill';\n\n$jscomp.polyfill('Array.prototype.findIndex', function(orig) {\n if (orig) return orig;\n\n /**\n * Finds an element that satisfies the given predicate, returning its index.\n *\n * @this {!IArrayLike}\n * @param {function(this: THIS, VALUE, number, !IArrayLike): *}\n * callback\n * @param {THIS=} opt_thisArg\n * @return {number} The found value, or undefined.\n * @template VALUE, THIS\n * @suppress {reportUnknownTypes}\n */\n var polyfill = function(callback, opt_thisArg) {\n return $jscomp.findInternal(this, callback, opt_thisArg).i;\n };\n\n return polyfill;\n}, 'es6', 'es3');\n","/*\n * Copyright 2019 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @fileoverview\n * @suppress {uselessCode}\n */\n'require es6/symbol';\n'require util/defineproperty';\n'require util/polyfill';\n\n$jscomp.polyfill('Object.fromEntries', function(orig) {\n if (orig) {\n return orig;\n }\n\n /**\n * @param {!Iterable<*>} iter\n * @return {!Object}\n * @see https://github.com/tc39/proposal-object-from-entries/blob/master/polyfill.js\n */\n function fromEntries(iter) {\n var obj = {};\n\n if (!(Symbol.iterator in iter)) {\n throw new TypeError('' + iter + ' is not iterable');\n }\n\n var iteratorFn = (/** @type {function(): !Iterator>} */ (\n iter[Symbol.iterator]));\n var iterator = iteratorFn.call(iter);\n\n for (var result = iterator.next(); !result.done; result = iterator.next()) {\n var pair = result.value;\n\n if (Object(pair) !== pair) {\n throw new TypeError('iterable for fromEntries should yield objects');\n }\n\n var key = pair[0];\n var val = pair[1];\n obj[key] = val;\n }\n\n return obj;\n }\n\n return fromEntries;\n}, 'es_2019', 'es3');\n","/*\n * Copyright 2017 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/owns';\n'require util/polyfill';\n\n$jscomp.polyfill('Object.entries', function(orig) {\n if (orig) return orig;\n\n /**\n * Returns an array of [key, value] arrays, one for each entry\n * in the given object.\n *\n * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/entries\n *\n * @param {!Object} obj\n * @return {!Array>}\n * @template KEY, VALUE\n */\n var entries = function(obj) {\n var result = [];\n for (var key in obj) {\n if ($jscomp.owns(obj, key)) {\n result.push([key, obj[key]]);\n }\n }\n return result;\n };\n\n return entries;\n}, 'es8', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require util/checkstringargs';\n'require util/polyfill';\n\n$jscomp.polyfill('String.prototype.startsWith', function(orig) {\n if (orig) return orig;\n\n /**\n * Tests whether the string starts with a given substring.\n *\n *

Polyfills the instance method String.prototype.startsWith().\n *\n * @this {string}\n * @param {string} searchString\n * @param {number=} opt_position\n * @return {boolean}\n */\n var polyfill = function(searchString, opt_position) {\n 'use strict';\n var string = $jscomp.checkStringArgs(this, searchString, 'startsWith');\n searchString = searchString + '';\n var strLen = string.length;\n var searchLen = searchString.length;\n var i = Math.max(\n 0,\n Math.min(/** @type {number} */ (opt_position) | 0, string.length));\n var j = 0;\n while (j < searchLen && i < strLen) {\n if (string[i++] != searchString[j++]) return false;\n }\n return j >= searchLen;\n };\n\n return polyfill;\n}, 'es6', 'es3');\n","/*\n * Copyright 2016 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n'require es6/util/iteratorfromarray';\n'require util/polyfill';\n\n// NOTE: Although Array.prototype.values was added to the 2015 edition of the\n// spec, we consider it an \"ES8\" feature because many browsers which are\n// otherwise ES6-compatible, have not implemented it due to web compatibility\n// issues. See https://bugs.chromium.org/p/chromium/issues/detail?id=615873\n$jscomp.polyfill('Array.prototype.values', function(orig) {\n if (orig) return orig;\n\n /**\n * Returns an iterator of values of the given array.\n *\n * @this {!IArrayLike}\n * @return {!IteratorIterable}\n * @template VALUE\n * @suppress {reportUnknownTypes}\n */\n var polyfill = function() {\n return $jscomp.iteratorFromArray(this, function(k, v) { return v; });\n };\n\n return polyfill;\n}, 'es8', 'es3');\n","/*\n * See the NOTICE file distributed with this work for additional\n * information regarding copyright ownership.\n *\n * This is free software; you can redistribute it and/or modify it\n * under the terms of the GNU Lesser General Public License as\n * published by the Free Software Foundation; either version 2.1 of\n * the License, or (at your option) any later version.\n *\n * This software is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this software; if not, write to the Free\n * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n * 02110-1301 USA, or see the FSF site: http://www.fsf.org.\n */\n\n\ndefine('xwiki-livedata', [\n \"vue\",\n \"vue-i18n\",\n \"xwiki-livedata-vue\",\n \"xwiki-livedata-source\",\n \"xwiki-json-merge\",\n \"edit-bus\",\n \"xwiki-livedata-polyfills\"\n], function(\n Vue,\n VueI18n,\n XWikiLivedata,\n liveDataSource,\n jsonMerge,\n editBus\n) {\n\n /**\n * Make vue use the i18n plugin\n */\n Vue.use(VueI18n);\n\n\n /**\n * Map the element to its data object\n * So that each instance of the livedata on the page handle there own data\n */\n const instancesMap = new WeakMap();\n\n\n\n /**\n * The init function of the logic script\n * For each livedata element on the page, returns its corresponding data / API\n * If the data does not exists yet, create it from the element\n * @param {HTMLElement} element The HTML Element corresponding to the Livedata component\n */\n const init = function (element) {\n\n if (!instancesMap.has(element)) {\n // create a new logic object associated to the element\n const logic = new Logic(element);\n instancesMap.set(element, logic);\n }\n\n return instancesMap.get(element);\n };\n\n /**\n * A service providing footnotes related operations. \n */\n class FootnotesService {\n constructor() {\n this._footnotes = [];\n }\n\n /**\n * Register a new footnote. If a footnote with the same translationKey is already registered this method has no\n * effect on the list of registered footnotes.\n * @param symbol the symbol to identify the entries related to the footnote \n * @param translationKey the translation key of the footnote text \n */\n put(symbol, translationKey) {\n if (!this._footnotes.some(footnote => footnote.translationKey === translationKey)) {\n this._footnotes.push({symbol, translationKey});\n }\n }\n \n reset() {\n this._footnotes.splice(0);\n }\n \n list() {\n return this._footnotes;\n }\n }\n\n /**\n * Class for a logic element\n * Contains the Livedata data object and methods to mutate it\n * Can be used in the layouts to display the data, and call its API\n * @param {HTMLElement} element The HTML Element corresponding to the Livedata\n */\n const Logic = function (element) {\n this.element = element;\n this.data = JSON.parse(element.getAttribute(\"data-config\") || \"{}\");\n if(this.data.entries) {\n // Calling Object.freeze(undefined) on IE11 triggers an exception. \n this.data.entries = Object.freeze(this.data.entries);\n }\n\n // Reactive properties must be initialized before Vue is instantiated.\n this.firstEntriesLoading = true;\n this.currentLayoutId = \"\";\n this.changeLayout(this.data.meta.defaultLayout);\n this.entrySelection = {\n selected: [],\n deselected: [],\n isGlobal: false,\n };\n this.openedPanels = [];\n this.footnotes = new FootnotesService();\n\n element.removeAttribute(\"data-config\");\n\n const locale = document.documentElement.getAttribute('lang');\n\n const i18n = new VueI18n({\n locale: locale,\n messages: {},\n silentFallbackWarn: true,\n });\n\n // create Vuejs instance\n const vue = new Vue({\n el: this.element,\n components: {\n \"XWikiLivedata\": XWikiLivedata,\n },\n template: \"\",\n i18n: i18n,\n data: {\n logic: this\n },\n });\n\n // Fetch the data if we don't have any. This call must be made just after the main Vue component is initialized as \n // LivedataPersistentConfiguration must be mounted for the persisted filters to be loaded and applied when fetching \n // the entries.\n // We use a dedicated field (firstEntriesLoading) for the first load as the fetch start/end events can be triggered \n // before the loader components is loaded (and in this case the loader is never hidden even once the entries are\n // displayed).\n if (!this.data.data.entries.length) {\n this.updateEntries()\n // Mark the loader as finished, even if it fails as the loader should stop and a message be displayed to the \n // user in this case.\n .finally(() => this.firstEntriesLoading = false);\n } else {\n this.firstEntriesLoading = false;\n }\n\n editBus.init(this);\n\n /**\n * Load given translations from the server\n *\n * @param {object} parameters\n * @param {string} componentName The name component who needs the translations\n * Used to avoid loading the same translations several times\n * @param {string} prefix The translation keys prefix\n * @param {string[]} keys\n */\n this.loadTranslations = async function ({ componentName, prefix, keys }) {\n // If translations were already loaded, return.\n if (this.loadTranslations[componentName]) return;\n this.loadTranslations[componentName] = true;\n // Fetch translation and load them.\n try {\n const translations = await liveDataSource.getTranslations(locale, prefix, keys);\n i18n.mergeLocaleMessage(locale, translations)\n } catch (error) {\n console.error(error);\n }\n }\n\n // Load needed translations for the Livedata\n const translationsPromise = this.loadTranslations({\n prefix: \"livedata.\",\n keys: [\n \"dropdownMenu.title\",\n \"dropdownMenu.actions\",\n \"dropdownMenu.layouts\",\n \"dropdownMenu.panels\",\n \"dropdownMenu.panels.properties\",\n \"dropdownMenu.panels.sort\",\n \"dropdownMenu.panels.filter\",\n \"selection.selectInAllPages\",\n \"selection.infoBar.selectedCount\",\n \"selection.infoBar.allSelected\",\n \"selection.infoBar.allSelectedBut\",\n \"pagination.currentEntries\",\n \"pagination.pageSize\",\n \"pagination.page\",\n \"pagination.first\",\n \"pagination.previous\",\n \"pagination.next\",\n \"pagination.last\",\n \"action.refresh\",\n \"action.addEntry\",\n \"action.reorder.hint\",\n \"action.resizeColumn.hint\",\n \"panel.filter.title\",\n \"panel.filter.noneFilterable\",\n \"panel.filter.addConstraint\",\n \"panel.filter.addProperty\",\n \"panel.filter.delete\",\n \"panel.filter.deleteAll\",\n \"panel.properties.title\",\n \"panel.sort.title\",\n \"panel.sort.noneSortable\",\n \"panel.sort.direction.ascending\",\n \"panel.sort.direction.descending\",\n \"panel.sort.add\",\n \"panel.sort.delete\",\n \"displayer.emptyValue\",\n \"displayer.link.noValue\",\n \"displayer.boolean.true\",\n \"displayer.boolean.false\",\n \"displayer.xObjectProperty.missingDocumentName.errorMessage\",\n \"displayer.xObjectProperty.failedToRetrieveField.errorMessage\",\n \"displayer.actions.edit\",\n \"displayer.actions.followLink\",\n \"filter.list.emptyLabel\",\n \"footnotes.computedTitle\",\n \"footnotes.propertyNotViewable\",\n \"bottombar.noEntries\",\n \"error.updateEntriesFailed\"\n ],\n });\n\n // Return a translation only once the translations have been loaded from the server.\n this.translate = async (key, ...args) => {\n // Make sure that the translations are loaded from the server before translating.\n await translationsPromise;\n return vue.$t(key, args);\n }\n \n // Waits for the translations to be loaded before continuing.\n this.translationsLoaded = async() => {\n await translationsPromise;\n }\n };\n\n\n\n\n /**\n * THE LOGIC API\n */\n Logic.prototype = {\n\n\n /**\n * ---------------------------------------------------------------\n * EVENTS\n */\n\n\n /**\n * Send custom events\n * @param {String} eventName The name of the event, without the prefix \"xwiki:livedata\"\n * @param {Object} eventData The data associated with the event.\n * The livedata object reference is automatically added\n */\n triggerEvent (eventName, eventData) {\n // configure event\n const defaultData = {\n livedata: this,\n };\n eventName = \"xwiki:livedata:\" + eventName;\n eventData = {\n bubbles: true,\n detail: Object.assign(defaultData, eventData),\n };\n const event = new CustomEvent(eventName, eventData);\n // dispatch event\n this.element.dispatchEvent(event);\n },\n\n /**\n * Listen for custom events\n * @param {String} eventName The name of the event, without the prefix \"xwiki:livedata\"\n * @param {Function} callback Function to call we the event is triggered: e => { ... }\n */\n onEvent (eventName, callback) {\n eventName = \"xwiki:livedata:\" + eventName;\n this.element.addEventListener(eventName, function (e) {\n callback(e);\n });\n },\n\n\n /**\n * Listen for custom events, mathching certain conditions\n * @param {String} eventName The name of the event, without the prefix \"xwiki:livedata\"\n * @param {Object|Function} condition The condition to execute the callback\n * if Object, values of object properties must match e.detail properties values\n * if Function, the function must return true. e.detail is passed as argument\n * @param {Function} callback Function to call we the event is triggered: e => { ... }\n */\n onEventWhere (eventName, condition, callback) {\n eventName = \"xwiki:livedata:\" + eventName;\n this.element.addEventListener(eventName, function (e) {\n // Object check\n if (typeof condition === \"object\") {\n const isDetailMatching = (data, detail) => Object.keys(data).every(key => {\n return typeof data[key] === \"object\"\n ? isDetailMatching(data[key], detail?.[key])\n : Object.is(data[key], detail?.[key]);\n });\n if (!isDetailMatching(condition, e.detail)) { return; }\n }\n // Function check\n if (typeof condition === \"function\") {\n if (!condition(e.detail)) { return; }\n }\n // call callback\n callback(e);\n });\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * UTILS\n */\n\n\n /**\n * Return the list of layout ids\n * @returns {Array}\n */\n getLayoutIds () {\n return this.data.meta.layouts.map(layoutDescriptor => layoutDescriptor.id);\n },\n\n\n /**\n * Return the id of the given entry\n * @param {Object} entry\n * @returns {String}\n */\n getEntryId (entry) {\n const idProperty = this.data.meta.entryDescriptor.idProperty || \"id\";\n if (entry[idProperty] === undefined) {\n console.warn(\"Entry has no id (at property [\" + idProperty + \"]\", entry);\n return;\n }\n return entry[idProperty];\n },\n\n /*\n As Sets are not reactive in Vue 2.x, if we want to create\n a reactive collection of unique objects, we have to use arrays.\n So here are some handy functions to do what Sets do, but with arrays\n */\n\n /**\n * Return whether the array has the given item\n * @param {Array} uniqueArray An array of unique items\n * @param {Any} item\n */\n uniqueArrayHas (uniqueArray, item) {\n return uniqueArray.includes(item);\n },\n\n\n /**\n * Add the given item if not present in the array, or does nothing\n * @param {Array} uniqueArray An array of unique items\n * @param {Any} item\n */\n uniqueArrayAdd (uniqueArray, item) {\n if (this.uniqueArrayHas(uniqueArray, item)) { return; }\n uniqueArray.push(item);\n },\n\n\n /**\n * Remove the given item from the array if present, or does nothing\n * @param {Array} uniqueArray An array of unique items\n * @param {Any} item\n */\n uniqueArrayRemove (uniqueArray, item) {\n const index = uniqueArray.indexOf(item);\n if (index === -1) { return; }\n uniqueArray.splice(index, 1);\n },\n\n\n /**\n * Toggle the given item from the array, ensuring its uniqueness\n * @param {Array} uniqueArray An array of unique items\n * @param {Any} item\n * @param {Boolean} force Optional: true force add / false force remove\n */\n uniqueArrayToggle (uniqueArray, item, force) {\n if (force === undefined) {\n force = !this.uniqueArrayHas(uniqueArray, item);\n }\n if (force) {\n this.uniqueArrayAdd(uniqueArray, item);\n } else {\n this.uniqueArrayRemove(uniqueArray, item);\n }\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * DESCRIPTORS\n */\n\n\n /**\n * Returns the property descriptors of displayable properties\n * @returns {Array}\n */\n getPropertyDescriptors () {\n return this.data.query.properties.map(propertyId => this.getPropertyDescriptor(propertyId));\n },\n\n\n /**\n * Return the property descriptor corresponding to a property id\n * @param {String} propertyId\n * @returns {Object}\n */\n getPropertyDescriptor (propertyId) {\n const propertyDescriptor = this.data.meta.propertyDescriptors\n .find(propertyDescriptor => propertyDescriptor.id === propertyId);\n if (!propertyDescriptor) {\n console.error(\"Property descriptor of property `\" + propertyId + \"` does not exists\");\n }\n return propertyDescriptor;\n },\n\n\n /**\n * Return the property type descriptor corresponding to a property id\n * @param {String} propertyId\n * @returns {Object}\n */\n getPropertyTypeDescriptor (propertyId) {\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n if (!propertyDescriptor) { return; }\n return this.data.meta.propertyTypes\n .find(typeDescriptor => typeDescriptor.id === propertyDescriptor.type);\n },\n\n\n /**\n * Return the layout descriptor corresponding to a layout id\n * @param {String} propertyId\n * @returns {Object}\n */\n getLayoutDescriptor (layoutId) {\n return this.data.meta.layouts\n .find(layoutDescriptor => layoutDescriptor.id === layoutId);\n },\n\n\n /**\n * Get the displayer descriptor associated to a property id\n * @param {String} propertyId\n * @returns {Object}\n */\n getDisplayerDescriptor (propertyId) {\n // Property descriptor config\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n // Property type descriptor config\n const typeDescriptor = this.getPropertyTypeDescriptor(propertyId);\n // Merge the property and type displayer descriptors.\n const customDisplayerDescriptor = jsonMerge({}, typeDescriptor?.displayer, propertyDescriptor?.displayer);\n // Get the default displayer descriptor.\n const displayerId = customDisplayerDescriptor.id || this.data.meta.defaultDisplayer;\n const defaultDisplayerDescriptor = this.data.meta.displayers.find(displayer => displayer.id === displayerId);\n // Merge displayer descriptors.\n return jsonMerge({}, defaultDisplayerDescriptor, customDisplayerDescriptor);\n },\n\n\n /**\n * Get the filter descriptor associated to a property id\n * @param {String} propertyId\n * @returns {Object}\n */\n getFilterDescriptor(propertyId) {\n // Property descriptor config\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n // Property type descriptor config\n const typeDescriptor = this.getPropertyTypeDescriptor(propertyId);\n // Merge the property and type filter descriptors.\n const customFilterDescriptor = jsonMerge({}, typeDescriptor?.filter, propertyDescriptor?.filter);\n // Get the default filter descriptor.\n const filterId = customFilterDescriptor.id || this.data.meta.defaultFilter;\n const defaultFilterDescriptor = this.data.meta.filters.find(filter => filter.id === filterId);\n // Merge filter descriptors.\n return jsonMerge({}, defaultFilterDescriptor, customFilterDescriptor);\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * LAYOUT\n */\n\n\n /**\n * Fetch the entries of the current page according to the query configuration.\n * @returns the fetched entries\n */\n fetchEntries() {\n // Before fetch event\n this.triggerEvent(\"beforeEntryFetch\");\n // Fetch entries from data source\n return liveDataSource.getEntries(this.data.query)\n .then(data => {\n // After fetch event\n return data\n })\n .finally(() => this.triggerEvent(\"afterEntryFetch\"));\n },\n\n\n updateEntries () {\n return this.fetchEntries()\n .then(data => {\n if(data) {\n // Calling Object.freeze(undefined) on IE11 triggers an exception.\n this.data.data = Object.freeze(data);\n } else {\n this.data.data = undefined;\n }\n // Remove the outdated footnotes, they will be recomputed by the new entries.\n this.footnotes.reset()\n })\n .catch(err => {\n // Prevent undesired notifications of the end user for non business related errors (for instance, the user\n // left the page before the request was completed).\n // See https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/readyState\n if (err.readyState === 4) {\n this.translate('livedata.error.updateEntriesFailed')\n .then(value => new XWiki.widgets.Notification(value, 'error'));\n }\n console.error('Failed to fetch the entries', err)\n });\n },\n\n\n /**\n * Return whether the Livedata is editable or not\n * if entry given, return whether it is editable\n * if property given, return whether it is editable (for any entries)\n * If entry and property given, return whether specific value is editable\n * @param {Object} [parameters]\n * @param {Object} [parameters.entry] The entry object\n * @param {Number} [parameters.propertyId] The property id of the entry\n */\n isEditable ({ entry, propertyId } = {}) {\n // TODO: Ensure entry is valid (need other current PR)\n // TODO: Ensure property is valid (need other current PR)\n\n // Check if the edit entry action is available.\n if (!this.data.meta.actions.find(action => action.id === \"edit\")) {\n return false;\n }\n\n // Check if we are allowed to edit the given entry.\n if (entry && !this.isEntryEditable(entry)) {\n return false;\n }\n\n // Check if the specified property is editable.\n return !propertyId || this.isPropertyEditable(propertyId);\n },\n\n /**\n * Returns whether the given entry is editable or not.\n *\n * @param {Object} entry\n * @returns {Boolean}\n */\n isEntryEditable (entry) {\n return this.isActionAllowed('edit', entry);\n },\n\n /**\n * Returns whether a certain property is editable or not.\n *\n * @param {String} propertyId\n * @returns {Boolean}\n */\n isPropertyEditable (propertyId) {\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n const propertyTypeDescriptor = this.getPropertyTypeDescriptor(propertyId);\n return propertyDescriptor && (propertyDescriptor.editable !== undefined ? propertyDescriptor.editable :\n (propertyTypeDescriptor && propertyTypeDescriptor.editable));\n },\n\n /**\n * Set the value of the given entry property\n * @param {Object} parameters\n * @param {Object} parameters.entry The entry we want to modify\n * @param {number} parameters.propertyId The property id we want to modify in the entry\n * @param {string} parameters.value The new value of entry property\n */\n setValue({entry, propertyId, value}) {\n // TODO: Ensure entry is valid (need other current PR)\n // TODO: Ensure property is valid (need other current PR)\n if (!this.isEditable({entry, propertyId})) {\n return;\n }\n entry[propertyId] = value;\n const source = this.data.query.source;\n const entryId = this.getEntryId(entry);\n // Once the entry updated, reload the whole livedata because changing a single entry can have an impact on other \n // properties of the entry, but also possibly on other entriers, or in the way they are sorted.\n liveDataSource.updateEntryProperty(source, entryId, propertyId, entry[propertyId])\n .then(() => this.updateEntries());\n },\n\n /**\n * Update the entry with the values object passed in parameter and s\n * @param {Object} entry the current entry\n * @param {Object} values the entry's values to update\n */\n setValues({entryId, values}) {\n const source = this.data.query.source;\n return liveDataSource.updateEntry(source, entryId, values)\n .then(() => this.updateEntries());\n\n },\n\n\n /**\n * Return whether adding new entries is enabled.\n */\n canAddEntry () {\n // Check if the add entry action is available.\n return this.data.meta.actions.find(action => action.id === \"addEntry\");\n },\n\n addEntry () {\n if (!this.canAddEntry()) { return; }\n const mockNewUrl = () => this.getEntryId(this.data.data.entries.slice(-1)[0]) + \"0\";\n // TODO: CALL FUNCTION TO CREATE NEW DATA HERE\n Promise.resolve({ /* MOCK DATA */\n \"doc_url\": mockNewUrl(),\n \"doc_name\": undefined,\n \"doc_date\": \"1585311660000\",\n \"doc_title\": undefined,\n \"doc_author\": \"Author 1\",\n \"doc_creationDate\": \"1585311660000\",\n \"doc_creator\": \"Creator 1\",\n \"age\": undefined,\n \"tags\": undefined,\n \"country\": undefined,\n \"other\": undefined,\n })\n .then(newEntry => {\n this.data.data.entries.push(newEntry);\n this.data.data.count++; // TODO: remove when merging with backend\n });\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * LAYOUT\n */\n\n\n /**\n * Load a layout, or default layout if none specified\n * @param {String} layoutId The id of the layout to load with requireJS\n * @returns {Promise}\n */\n changeLayout (layoutId) {\n // bad layout\n if (!this.getLayoutDescriptor(layoutId)) {\n console.error(\"Layout of id `\" + layoutId + \"` does not have a descriptor\");\n return;\n }\n // set layout\n const previousLayoutId = this.currentLayoutId;\n this.currentLayoutId = layoutId;\n // dispatch events\n this.triggerEvent(\"layoutChange\", {\n layoutId: layoutId,\n previousLayoutId: previousLayoutId,\n });\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * PAGINATION\n */\n\n\n /**\n * Get total number of pages\n * @returns {Number}\n */\n getPageCount () {\n return Math.ceil(this.data.data.count / this.data.query.limit);\n },\n\n\n /**\n * Get the page corresponding to the specified entry (0-based index)\n * @param {Number} entryIndex The index of the entry. Uses current entry if undefined.\n * @returns {Number}\n */\n getPageIndex (entryIndex) {\n if (entryIndex === undefined) {\n entryIndex = this.data.query.offset;\n }\n return Math.floor(entryIndex / this.data.query.limit);\n },\n\n\n /**\n * Set page index (0-based index), then fetch new data\n * @param {Number} pageIndex\n * @returns {Promise}\n */\n setPageIndex (pageIndex) {\n return new Promise ((resolve, reject) => {\n if (pageIndex < 0 || pageIndex >= this.getPageCount()) { return void reject(); }\n const previousPageIndex = this.getPageIndex();\n this.data.query.offset = this.getFirstIndexOfPage(pageIndex);\n this.triggerEvent(\"pageChange\", {\n pageIndex: pageIndex,\n previousPageIndex: previousPageIndex,\n });\n this.updateEntries().then(resolve, reject);\n });\n },\n\n\n /**\n * Get the first entry index of the given page index\n * @param {Number} pageIndex The page index. Uses current page if undefined.\n * @returns {Number}\n */\n getFirstIndexOfPage (pageIndex) {\n if (pageIndex === undefined) {\n pageIndex = this.getPageIndex();\n }\n if (0 <= pageIndex && pageIndex < this.getPageCount()) {\n return pageIndex * this.data.query.limit;\n } else {\n return -1;\n }\n },\n\n\n /**\n * Get the last entry index of the given page index\n * @param {Number} pageIndex The page index. Uses current page if undefined.\n * @returns {Number}\n */\n getLastIndexOfPage (pageIndex) {\n if (pageIndex === undefined) {\n pageIndex = this.getPageIndex();\n }\n if (0 <= pageIndex && pageIndex < this.getPageCount()) {\n return Math.min(this.getFirstIndexOfPage(pageIndex) + this.data.query.limit, this.data.data.count) - 1;\n } else {\n return -1;\n }\n },\n\n\n /**\n * Set the pagination page size, then fetch new data\n * @param {Number} pageSize\n * @returns {Promise}\n */\n setPageSize (pageSize) {\n return new Promise ((resolve, reject) => {\n if (pageSize < 0) { return void reject(); }\n const previousPageSize = this.data.query.limit;\n if (pageSize === previousPageSize) { return void resolve(); }\n this.data.query.limit = pageSize;\n // Reset the offset whenever the page size changes.\n this.data.query.offset = 0;\n this.triggerEvent(\"pageSizeChange\", {\n pageSize: pageSize,\n previousPageSize: previousPageSize,\n });\n this.updateEntries().then(resolve, reject);\n });\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * DISPLAY\n */\n\n\n /**\n * Returns whether a certain property is visible\n * @param {String} propertyId\n * @returns {Boolean}\n */\n isPropertyVisible (propertyId) {\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n return propertyDescriptor.visible;\n },\n\n\n /**\n * Set whether the given property should be visible\n * @param {String} propertyId\n * @param {Boolean} visible\n */\n setPropertyVisible (propertyId, visible) {\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n propertyDescriptor.visible = visible;\n },\n\n\n /**\n * Move a property to a certain index in the property order list\n * @param {String|Number} from The id or index of the property to move\n * @param {Number} toIndex\n */\n reorderProperty (from, toIndex) {\n let fromIndex;\n if (typeof from === \"number\") {\n fromIndex = from;\n } else if (typeof from === \"string\") {\n fromIndex = this.data.query.properties.indexOf(from);\n } else {\n return;\n }\n if (fromIndex < 0 || toIndex < 0) { return; }\n this.data.query.properties.splice(toIndex, 0, this.data.query.properties.splice(fromIndex, 1)[0]);\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * SELECTION\n */\n\n\n /**\n * Return whether selecting entries is enabled. If an entry is given, return whether that entry can be selected.\n *\n * @param {Object} [parameters]\n * @param {Object} [parameters.entry]\n */\n isSelectionEnabled ({ entry } = {}) {\n // An entry is selectable if it has an id specified.\n return this.data.meta.selection.enabled && (!entry || this.getEntryId(entry));\n },\n\n\n /**\n * Return whether the entry is currently selected\n * @param {Object} entry\n * @returns {Boolean}\n */\n isEntrySelected (entry) {\n const entryId = this.getEntryId(entry);\n if (this.entrySelection.isGlobal) {\n return !this.uniqueArrayHas(this.entrySelection.deselected, entryId);\n } else {\n return this.uniqueArrayHas(this.entrySelection.selected, entryId);\n }\n },\n\n\n /**\n * Select the specified entries\n * @param {Object|Array} entries\n */\n selectEntries (entries) {\n if (!this.isSelectionEnabled()) { return; }\n const entryArray = (entries instanceof Array) ? entries : [entries];\n entryArray.forEach(entry => {\n if (!this.isSelectionEnabled({ entry })) { return; }\n const entryId = this.getEntryId(entry);\n if (this.entrySelection.isGlobal) {\n this.uniqueArrayRemove(this.entrySelection.deselected, entryId);\n }\n else {\n this.uniqueArrayAdd(this.entrySelection.selected, entryId);\n }\n this.triggerEvent(\"select\", {\n entry: entry,\n });\n });\n },\n\n\n /**\n * Deselect the specified entries\n * @param {Object|Array} entries\n */\n deselectEntries (entries) {\n if (!this.isSelectionEnabled()) { return; }\n const entryArray = (entries instanceof Array) ? entries : [entries];\n entryArray.forEach(entry => {\n if (!this.isSelectionEnabled({ entry })) { return; }\n const entryId = this.getEntryId(entry);\n if (this.entrySelection.isGlobal) {\n this.uniqueArrayAdd(this.entrySelection.deselected, entryId);\n }\n else {\n this.uniqueArrayRemove(this.entrySelection.selected, entryId);\n }\n this.triggerEvent(\"deselect\", {\n entry: entry,\n });\n });\n },\n\n\n /**\n * Toggle the selection of the specified entries\n * @param {Object|Array} entries\n * @param {Boolean} select Whether to select or not the entries. Undefined toggle current state\n */\n toggleSelectEntries (entries, select) {\n if (!this.isSelectionEnabled()) { return; }\n const entryArray = (entries instanceof Array) ? entries : [entries];\n entryArray.forEach(entry => {\n if (!this.isSelectionEnabled({ entry })) { return; }\n if (select === undefined) {\n select = !this.isEntrySelected(entry);\n }\n if (select) {\n this.selectEntries(entry);\n } else {\n this.deselectEntries(entry);\n }\n });\n },\n\n\n /**\n * Get number of selectable entries in page\n * @returns {Number}\n */\n selectableCountInPage () {\n if (!this.isSelectionEnabled()) { return 0; }\n return this.data.data.entries\n .filter(entry => this.isSelectionEnabled({ entry }))\n .length;\n },\n\n\n /**\n * Set the entry selection globally accross pages\n * @param {Boolean} global\n */\n setEntrySelectGlobal (global) {\n if (!this.isSelectionEnabled()) { return; }\n this.entrySelection.isGlobal = global;\n this.entrySelection.selected.splice(0);\n this.entrySelection.deselected.splice(0);\n this.triggerEvent(\"selectGlobal\", {\n state: global,\n });\n },\n\n\n\n /**\n * ---------------------------------------------------------------\n * ACTIONS\n */\n\n\n /**\n * @param {String|Object} specifies the action\n * @returns {Object} the descriptor of the specified live data action\n */\n getActionDescriptor(action) {\n const descriptor = typeof action === 'string' ? {id: action} : action;\n const baseDescriptor = this.data.meta.actions.find(baseDescriptor => baseDescriptor.id === descriptor.id);\n return jsonMerge({}, baseDescriptor, descriptor);\n },\n\n\n /**\n * @param {String|Object} specifies the action\n * @param {Object} the live data entry that is the target of the action\n * @returns {Boolean} whether the specified action is allowed to target the specified live data entry\n */\n isActionAllowed(action, entry) {\n const actionDescriptor = this.getActionDescriptor(action);\n return !actionDescriptor.allowProperty || entry[actionDescriptor.allowProperty];\n },\n\n\n /**\n * ---------------------------------------------------------------\n * SORT\n */\n\n\n /**\n * Returns whether a certain property is sortable or not\n * @param {String} propertyId\n * @returns {Boolean}\n */\n isPropertySortable (propertyId) {\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n const propertyTypeDescriptor = this.getPropertyTypeDescriptor(propertyId);\n return propertyDescriptor && (propertyDescriptor.sortable !== undefined ? propertyDescriptor.sortable :\n (propertyTypeDescriptor && propertyTypeDescriptor.sortable));\n },\n\n\n /**\n * Returns the sortable properties from the live data query.\n *\n * @returns {Array}\n */\n getSortableProperties () {\n return this.data.query.properties.filter(property => this.isPropertySortable(property));\n },\n\n\n /**\n * Returns the sortable properties that don't have a sort entry in the live data query.\n *\n * @returns {Array}\n */\n getUnsortedProperties () {\n return this.getSortableProperties().filter(property => !this.getQuerySort(property));\n },\n\n\n /**\n * Get the sort query associated to a property id\n * @param {String} propertyId\n */\n getQuerySort (propertyId) {\n return this.data.query.sort.find(sort => sort.property === propertyId);\n },\n\n\n /**\n * Update sort configuration based on parameters, then fetch new data\n * @param {String} property The property to sort according to\n * @param {String} level The sort level for the property (0 is the highest).\n * Undefined means keep current. Negative value removes property sort.\n * @param {String} descending Specify whether the sort should be descending or not.\n * Undefined means toggle current direction\n * @returns {Promise}\n */\n sort (property, level, descending) {\n const err = new Error(\"Property `\" + property + \"` is not sortable\");\n return new Promise ((resolve, reject) => {\n // Allow the user to remove a sort entry (level < 0) even if the property is not sortable.\n if (!(level < 0 || this.isPropertySortable(property))) {\n return void reject(err);\n }\n // find property current sort level\n const currentLevel = this.data.query.sort.findIndex(sortObject => sortObject.property === property);\n // default level\n if (level === undefined) {\n level = (currentLevel !== -1) ? currentLevel : 0;\n } else if (level < 0) {\n level = -1;\n }\n // default descending\n if (descending === undefined) {\n descending = (currentLevel !== -1) ? !this.data.query.sort[currentLevel].descending : false;\n }\n // create sort object\n const sortObject = {\n property: property,\n descending: descending,\n };\n // apply sort\n if (level !== -1) {\n this.data.query.sort.splice(level, 1, sortObject);\n }\n if (currentLevel !== -1 && currentLevel !== level) {\n this.data.query.sort.splice(currentLevel, 1);\n }\n // dispatch events\n this.triggerEvent(\"sort\", {\n property: property,\n level: level,\n descending: descending,\n });\n\n this.updateEntries().then(resolve, reject);\n });\n },\n\n\n /**\n * Add new sort entry, shorthand of sort:\n * If the property is already sorting, does nothing\n * @param {String} property The property to add to the sort\n * @param {String} descending Specify whether the sort should be descending or not.\n * Undefined means toggle current direction\n * @returns {Promise}\n */\n addSort (property, descending) {\n const err = new Error(\"Property `\" + property + \"` is already sorting\");\n const propertyQuerySort = this.data.query.sort.find(sortObject => sortObject.property === property);\n if (propertyQuerySort) { return Promise.reject(err); }\n return this.sort(property, this.data.query.sort.length, descending);\n },\n\n\n /**\n * Remove a sort entry, shorthand of sort:\n * @param {String} property The property to remove to the sort\n * @returns {Promise}\n */\n removeSort (property) {\n return this.sort(property, -1);\n },\n\n\n /**\n * Move a sort entry to a certain index in the query sort list\n * @param {String} property The property to reorder the sort\n * @param {Number} toIndex\n */\n reorderSort (propertyId, toIndex) {\n const err = new Error(\"Property `\" + propertyId + \"` is not sortable\");\n return new Promise ((resolve, reject) => {\n const fromIndex = this.data.query.sort.findIndex(querySort => querySort.property === propertyId);\n if (fromIndex < 0 || toIndex < 0) { return void reject(err); }\n this.data.query.sort.splice(toIndex, 0, this.data.query.sort.splice(fromIndex, 1)[0]);\n\n // dispatch events\n this.triggerEvent(\"sort\", {\n type: \"move\",\n property: propertyId,\n level: toIndex,\n });\n\n this.updateEntries().then(resolve, reject);\n });\n },\n\n\n\n\n /**\n * ---------------------------------------------------------------\n * FILTER\n */\n\n\n /**\n * Returns whether a certain property is filterable or not\n * @param {String} propertyId\n * @returns {Boolean}\n */\n isPropertyFilterable (propertyId) {\n const propertyDescriptor = this.getPropertyDescriptor(propertyId);\n const propertyTypeDescriptor = this.getPropertyTypeDescriptor(propertyId);\n return propertyDescriptor && (propertyDescriptor.filterable !== undefined ? propertyDescriptor.filterable :\n (propertyTypeDescriptor && propertyTypeDescriptor.filterable));\n },\n\n\n /**\n * Returns the filterable properties from the live data query.\n *\n * @returns {Array}\n */\n getFilterableProperties () {\n return this.data.query.properties.filter(property => this.isPropertyFilterable(property));\n },\n\n\n /**\n * Returns the filterable properties that don't have constraints in the live data query.\n *\n * @returns {Array}\n */\n getUnfilteredProperties () {\n return this.getFilterableProperties().filter(property => {\n const filter = this.getQueryFilterGroup(property);\n return !filter || filter.constraints.length === 0;\n });\n },\n\n\n /**\n * Get the filter in the query data object associated to a property id\n * @param {String} propertyId\n * @returns {Object}\n */\n getQueryFilterGroup (propertyId) {\n return this.data.query.filters.find(filter => filter.property === propertyId);\n },\n\n\n /**\n * Get the filters in the query data object associated to a property id\n * @param {String} propertyId\n * @returns {Array} The constraints array of the filter group, or empty array if it does not exist\n */\n getQueryFilters (propertyId) {\n const queryFilterGroup = this.getQueryFilterGroup(propertyId);\n return queryFilterGroup && queryFilterGroup.constraints || [];\n },\n\n\n /**\n * Get the default filter operator associated to a property id\n * @param {String} propertyId\n * @returns {String}\n */\n getFilterDefaultOperator (propertyId) {\n // get valid operator descriptor\n const filterDescriptor = this.getFilterDescriptor(propertyId);\n if (!filterDescriptor) { return; }\n const filterOperators = filterDescriptor.operators;\n if (!(filterOperators instanceof Array)) { return; }\n if (filterOperators.length === 0) { return; }\n // get default operator\n const defaultOperator = filterDescriptor.defaultOperator;\n const isDefaultOperatorValid = !!filterOperators.find(operator => operator.id === defaultOperator);\n if (defaultOperator && isDefaultOperatorValid) {\n return defaultOperator;\n } else {\n return filterOperators[0].id;\n }\n },\n\n\n /**\n * Return an object containing the new and old filter entries corresponding to parameters\n * oldEntry: the filter entry to be modified\n * newEntry: what this entry should be modified to\n * @param {String} property The property to filter according to\n * @param {String} index The index of the filter entry\n * @param {String} filterEntry The filter data used to update the filter configuration\n * (see Logic.prototype.filter for more)\n * @returns {Object} {oldEntry, newEntry}\n * with oldEntry / newEntry being {property, index, operator, value}\n */\n _computeFilterEntries (property, index, filterEntry, {filterOperator} = {}) {\n if (!this.isPropertyFilterable(property)) { return; }\n // default indexes\n index = index || 0;\n if (index < 0) { index = -1; }\n if (filterEntry.index < 0) { filterEntry.index = -1; }\n // old entry\n let oldEntry = {\n property: property,\n index: index,\n };\n const queryFilters = this.getQueryFilters(property);\n const currentEntry = queryFilters[index] || {};\n oldEntry = Object.assign({}, currentEntry, oldEntry);\n // new entry (copy properties that are not undefined from filterEntry)\n let newEntry = Object.fromEntries(Object.entries(filterEntry || {})\n .filter(entry => entry[1] !== undefined));\n const self = this;\n const defaultEntry = {\n property: property,\n value: \"\",\n operator: self.getFilterDefaultOperator(property),\n index: 0,\n };\n newEntry = Object.assign({}, defaultEntry, oldEntry, newEntry);\n if (filterOperator) {\n newEntry.operator = filterOperator;\n }\n // check newEntry operator\n const newEntryValidOperator = this.getFilterDescriptor(newEntry.property).operators\n .some(operator => operator.id === newEntry.operator);\n if (!newEntryValidOperator) {\n newEntry.operator = self.getFilterDefaultOperator(newEntry.property);\n }\n return {\n oldEntry: oldEntry,\n newEntry: newEntry,\n };\n },\n\n\n /**\n * Return the filtering type, based on oldEntry and newEntry\n * @param {Object} oldEntry\n * @param {Oject} newEntry\n * @returns {String} \"add\" | \"remove\" | \"move\" | \"modify\"\n */\n _getFilteringType (oldEntry, newEntry) {\n const queryFilter = this.getQueryFilterGroup(oldEntry.property);\n if (queryFilter && oldEntry.index === -1) {\n return \"add\";\n }\n if (newEntry.index === -1) {\n return \"remove\";\n }\n if (oldEntry.index !== newEntry.index) {\n return \"move\";\n }\n return \"modify\";\n },\n\n\n /**\n * Update filter configuration based on parameters, then fetch new data\n * @param {String} property The property to filter according to\n * @param {String} index The index of the filter entry\n * @param {String} filterEntry The filter data used to update the filter configuration\n * filterEntry = {property, operator, value}\n * undefined values are defaulted to current values, then to default values.\n * @param {String} filterEntry.property The new property to filter according to\n * @param {String} filterEntry.index The new index the filter should go. -1 delete filter\n * @param {String} filterEntry.operator The operator of the filter.\n * Should match the filter descriptor of the filter property\n * @param {String} filterEntry.value Value for the new filter entry\n * @returns {Promise}\n */\n filter(property, index, filterEntry, {filterOperator} = {}) {\n const err = new Error(\"Property `\" + property + \"` is not filterable\");\n return new Promise ((resolve, reject) => {\n const filterEntries = this._computeFilterEntries(property, index, filterEntry, {filterOperator});\n if (!filterEntries) { return void reject(err); }\n const oldEntry = filterEntries.oldEntry;\n const newEntry = filterEntries.newEntry;\n const filteringType = this._getFilteringType(oldEntry, newEntry);\n // remove filter at current property and index\n if (oldEntry.index !== -1) {\n this.getQueryFilters(oldEntry.property).splice(index, 1);\n }\n // add filter at new property and index\n if (newEntry.index !== -1) {\n // create filterGroup if not exists\n if (!this.getQueryFilterGroup(newEntry.property)) {\n this.data.query.filters.push({\n property: newEntry.property,\n // We use by default AND between filter groups (different properties) and OR inside a filter group (same\n // property)\n matchAll: false,\n constraints: [],\n });\n }\n // add entry\n this.getQueryFilterGroup(newEntry.property).constraints.splice(newEntry.index, 0, {\n operator: newEntry.operator,\n value: newEntry.value,\n });\n }\n // remove filter group if empty\n if (this.getQueryFilters(oldEntry.property).length === 0) {\n this.removeAllFilters(oldEntry.property);\n }\n // Reset the offset whenever the filters are updated.\n this.data.query.offset = 0;\n // dispatch events\n this.triggerEvent(\"filter\", {\n type: filteringType,\n oldEntry: oldEntry,\n newEntry: newEntry,\n });\n\n this.updateEntries().then(resolve, reject);\n });\n },\n\n\n /**\n * Add new filter entry, shorthand of filter:\n * @param {String} property Which property to add the filter to\n * @param {String} operator The operator of the filter. Should match the filter descriptor of the property\n * @param {String} value Default value for the new filter entry\n * @param {Number} index Index of new filter entry. Undefined means last\n * @returns {Promise}\n */\n addFilter (property, operator, value, index) {\n if (index === undefined) {\n index = ((this.getQueryFilterGroup(property) || {}).constraints || []).length;\n }\n return this.filter(property, -1, {\n property: property,\n operator: operator,\n value: value,\n index: index,\n });\n },\n\n\n /**\n * Remove a filter entry in the configuration, then fetch new data\n * @param {String} property Property to remove the filter to\n * @param {String} index The index of the filter to remove. Undefined means last.\n * @returns {Promise}\n */\n removeFilter (property, index) {\n return this.filter(property, index, {index: -1});\n },\n\n\n /**\n * Remove all the filters associated to a property\n * @param {String} property Property to remove the filters to\n * @returns {Promise}\n */\n removeAllFilters (property) {\n return new Promise ((resolve, reject) => {\n const filterIndex = this.data.query.filters\n .findIndex(filterGroup => filterGroup.property === property);\n if (filterIndex < 0) { return void reject(); }\n const removedFilterGroups = this.data.query.filters.splice(filterIndex, 1);\n // Reset the offset whenever the filters are updated.\n this.data.query.offset = 0;\n // dispatch events\n this.triggerEvent(\"filter\", {\n type: \"removeAll\",\n property: property,\n removedFilters: removedFilterGroups[0].constraints,\n });\n this.updateEntries().then(resolve, reject);\n });\n },\n \n //\n // Edit Bus\n //\n\n getEditBus() {\n return editBus;\n }\n };\n\n\n\n\n\n // return the init function to be used in the layouts\n return init;\n\n});\n\n\n\n","/*\n * See the NOTICE file distributed with this work for additional\n * information regarding copyright ownership.\n *\n * This is free software; you can redistribute it and/or modify it\n * under the terms of the GNU Lesser General Public License as\n * published by the Free Software Foundation; either version 2.1 of\n * the License, or (at your option) any later version.\n *\n * This software is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this software; if not, write to the Free\n * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n * 02110-1301 USA, or see the FSF site: http://www.fsf.org.\n */\n\ndefine('xwiki-livedata-xObjectPropertyHelper', ['jquery', 'xwiki-meta', 'xwiki-entityReference'], function($, xcontext, XWiki) {\n 'use strict';\n\n /**\n * Pass the vue-i18n helper to the module to allow error messages to be localized.\n * @param $t the vue-i18n localization helper\n */\n function setLocalization($t) {\n this.$t = $t;\n }\n \n /**\n * Resolve the url of the document reference in the given mode.\n * @param documentReference the document reference\n * @param mode the mode\n * @returns {*} the computed relative url\n */\n function computeTargetURL(documentReference, mode) {\n return new XWiki.Document(XWiki.Model.resolve(documentReference, XWiki.EntityType.DOCUMENT)).getURL(mode);\n }\n\n function getPropertyReference(propertyName, className) {\n if (propertyName.startsWith('doc.')) {\n return propertyName.substring('doc.'.length);\n } else {\n // We target the first object of the specified type (class name).\n return className + '[0].' + propertyName;\n }\n }\n \n function load(mode, documentReference, property, className) {\n const targetUrl = computeTargetURL(documentReference, 'get');\n return new Promise((resolve, reject) => {\n $.get(targetUrl, {\n xpage: 'display',\n mode: mode,\n // TODO: handle the object index when provided\n property: getPropertyReference(property, className),\n type: property.startsWith('doc.') ? 'document' : 'object',\n language: xcontext.locale\n }).done((html) => {\n // Update the viewer.\n resolve(html);\n }).fail(() => {\n new XWiki.widgets.Notification(\n this.$t('livedata.displayer.xObjectProperty.failedToRetrieveField.errorMessage', [mode]), 'error');\n reject();\n })\n });\n }\n\n /**\n * Load an XObject property field in edit mode.\n * @param documentReference the reference of the document containing the XObject\n * @param className the class name of the XObject\n * @param property the XObject property to display\n * @returns {*} the XObject property field html content in edit mode\n */\n function edit(documentReference, className, property) {\n return load('edit', documentReference, property, className);\n }\n\n /**\n * Load an XObject property field in view mode.\n * @param documentReference the reference of the document containing the XObject\n * @param className the class name of the XObject\n * @param property the XObject property to display\n * @returns {*} the XObject property field html content in view mode\n */\n function view(documentReference, className, property) {\n return load('view', documentReference, property, className);\n }\n\n return {edit, view, setLocalization};\n});\n","/*\n * See the NOTICE file distributed with this work for additional\n * information regarding copyright ownership.\n *\n * This is free software; you can redistribute it and/or modify it\n * under the terms of the GNU Lesser General Public License as\n * published by the Free Software Foundation; either version 2.1 of\n * the License, or (at your option) any later version.\n *\n * This software is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this software; if not, write to the Free\n * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n * 02110-1301 USA, or see the FSF site: http://www.fsf.org.\n */\n\n\n/**\n * Vue event bus for the edit action states.\n * Sent events:\n * - start-editing-entry({entryId, propertyId}): when an entry passes in edit mode\n * - cancel-editing-entry({entryId, propertyId}): when an entry goes out of edit mode without saving its edits\n * - save-editing-entry({entryId, propertyId, content}): when an entry goes out of edit model and wants to save its\n * edits. The content is an object mapping the keys and values of the cell form attributes.\n */\ndefine('edit-bus', ['vue'], (Vue) => {\n\n var _logic = undefined;\n var _editBus = new Vue();\n var _editBusService = undefined;\n\n /**\n * Centralizes the edition event listeners and maintain a centralized state of the edition states and results for the\n * live data.\n * This is useful to know when to save the table, and to know which cells can be edited according to the current edit\n * state\n */\n class EditBusService {\n\n /**\n * Default constructor.\n * @param editBus an edit bus Vue object\n * @param logic the live data logic instance\n */\n constructor(editBus, logic) {\n this.editBus = editBus;\n this.editStates = {};\n this.logic = logic;\n }\n\n /**\n * Initializes the Vue events listeners.\n */\n init() {\n this.editBus.$on('start-editing-entry', ({entryId, propertyId}) => {\n const entryState = this.editStates[entryId] || {};\n const propertyState = entryState[propertyId] || {};\n propertyState.editing = true;\n entryState[propertyId] = propertyState;\n this.editStates[entryId] = entryState;\n })\n\n this.editBus.$on('cancel-editing-entry', ({entryId, propertyId}) => {\n const entryState = this.editStates[entryId];\n const propertyState = entryState[propertyId];\n\n // The entry is not edited anymore.\n // The content is not edited, and should be `undefined` if the property was edited for the first time.\n // If the property was edited and saved a first time, then edited and cancelled, the content must stay to one from\n // the first edit.\n propertyState.editing = false;\n\n })\n\n this.editBus.$on('save-editing-entry', ({entryId, propertyId, content}) => {\n const entryState = this.editStates[entryId];\n const propertyState = entryState[propertyId];\n // The entry is not edited anymore but its content will need to be saved once the rest of the properties of the \n // entry are not in edit mode. \n propertyState.editing = false;\n propertyState.tosave = true;\n propertyState.content = content;\n this.save(entryId);\n })\n }\n\n /**\n * Save the changed values of an entry server side.\n * @param entryId the entry id of the entry to save\n */\n save(entryId) {\n const values = this.editStates[entryId];\n var canBeSaved = false;\n var keyEntry = undefined;\n\n\n // Look for the single cell to save.\n for (keyEntry in values) {\n const entryValue = values[keyEntry];\n\n const editing = entryValue.editing;\n const tosave = entryValue.tosave;\n canBeSaved = !editing && tosave;\n\n if (canBeSaved) break;\n }\n\n // If a cell to save is found, we get its content and save it. \n if (canBeSaved && keyEntry) {\n const vals = values[keyEntry].content;\n\n this.logic.setValues({entryId, values: vals})\n .then(() => {\n this.editStates[entryId] = {};\n })\n .catch(() => {\n new XWiki.widgets.Notification(`The row save action failed.`, 'error');\n })\n }\n }\n\n isEditable() {\n for (const editStatesKey in this.editStates) {\n const editStates = this.editStates[editStatesKey];\n for (const editStateKey in editStates) {\n const editState = editStates[editStateKey];\n if (editState.editing) {\n return false;\n }\n }\n }\n return true;\n }\n\n onAnyEvent(callback) {\n this.editBus.$on(['save-editing-entry', 'start-editing-entry', 'cancel-editing-entry'], () => callback())\n }\n }\n\n /**\n * Initialized the edit bus view and services.\n * @param logic the live data logic instance\n */\n function init(logic) {\n _logic = logic\n _editBusService = new EditBusService(_editBus, logic);\n _editBusService.init()\n }\n\n /**\n * Notifies the start of a cell modification. After this event, the cell is considered as edited unless it is\n * canceled.\n * @param entry the entry of the edited row\n * @param propertyId the property id of the edited cell.\n */\n function start(entry, propertyId) {\n _editBus.$emit('start-editing-entry', {\n entryId: _logic.getEntryId(entry),\n propertyId\n });\n\n }\n\n /**\n * Notifies the cancellation of the edition of a cell. The cell rollback to a non modified state.\n * @param entry the entry of the edited row\n * @param propertyId the property id of the edited cell\n */\n function cancel(entry, propertyId) {\n _editBus.$emit('cancel-editing-entry', {\n entryId: _logic.getEntryId(entry),\n propertyId\n })\n\n }\n\n /**\n * Notifies the save of the a cell. With the current save strategy, the cell is directly save and the table is reload\n * after this notification.\n * @param entry the entry of the edit row\n * @param propertyId the property id of the edited cell\n * @param content the attributes of the edit cell form, in the form of an object\n `\n */\n function save(entry, propertyId, content) {\n _editBus.$emit('save-editing-entry', {\n entryId: _logic.getEntryId(entry),\n propertyId: propertyId,\n content: content\n });\n }\n\n /**\n * Indicated if cells are allowed to switch to edit mode. For instance, a cell is not allowed to be edited if another\n * cell is already in edit mode. In this case the currently edited cell must be saved or cancelled before another one\n * can be edited.\n * @returns {*} true if the cells are allowed to switch to edit mode, false otherwise\n */\n function isEditable() {\n return _editBusService.isEditable();\n }\n \n function onAnyEvent(callback) {\n _editBusService.onAnyEvent(callback);\n }\n\n return {init, start, cancel, save, isEditable, onAnyEvent};\n})\n","/*\n * See the NOTICE file distributed with this work for additional\n * information regarding copyright ownership.\n *\n * This is free software; you can redistribute it and/or modify it\n * under the terms of the GNU Lesser General Public License as\n * published by the Free Software Foundation; either version 2.1 of\n * the License, or (at your option) any later version.\n *\n * This software is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this software; if not, write to the Free\n * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n * 02110-1301 USA, or see the FSF site: http://www.fsf.org.\n */\n\ndefine('xwiki-json-merge', function() {\n let merge = function(left, right) {\n if (left?.constructor === Object && right?.constructor === Object) {\n return mergeObject(left, right);\n } else if (Array.isArray(left) && Array.isArray(right)) {\n return mergeArray(left, right);\n } else if (right == null) {\n // Keep the left value.\n return left;\n } else {\n // Overwrite the left value because either it's null or we cannot merge.\n return deepCopy(right);\n }\n };\n\n let mergeArray = function(left, right) {\n // Take the items from the right, merging them with the corresponding item from the left.\n const fromRight = right.map(rightItem => merge(findById(rightItem.id, left), rightItem));\n // Take the items from the left that are identifiable and that are not present on the right.\n const fromLeft = deepCopy(left.filter(leftItem => leftItem.id != null && findById(leftItem.id, right) == null));\n return fromRight.concat(fromLeft);\n };\n\n let mergeObject = function(left, right) {\n // Don't merge if the right object has an identifier different than the one of the left object.\n if (right.hasOwnProperty('id') && left.id !== right.id) {\n return deepCopy(right);\n }\n Object.keys(right).forEach(key => {\n left[key] = merge(left[key], right[key]);\n });\n return left;\n };\n\n let deepCopy = function(value) {\n return JSON.parse(JSON.stringify(value));\n };\n\n let findById = function(id, array) {\n if (id != null) {\n return array.find(item => item.id === id);\n }\n };\n\n return function(...objects) {\n return objects?.reduce(merge, null);\n };\n});\n","/*\n * See the NOTICE file distributed with this work for additional\n * information regarding copyright ownership.\n *\n * This is free software; you can redistribute it and/or modify it\n * under the terms of the GNU Lesser General Public License as\n * published by the Free Software Foundation; either version 2.1 of\n * the License, or (at your option) any later version.\n *\n * This software is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this software; if not, write to the Free\n * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n * 02110-1301 USA, or see the FSF site: http://www.fsf.org.\n */\n\ndefine('xwiki-livedata-source', ['module', 'jquery'], function(module, $) {\n 'use strict';\n\n var baseURL = module.config().contextPath + '/rest/liveData/sources/';\n\n var getEntries = function(liveDataQuery) {\n var entriesURL = getEntriesURL(liveDataQuery.source);\n\n var parameters = {\n properties: liveDataQuery.properties,\n offset: liveDataQuery.offset,\n limit: liveDataQuery.limit\n };\n // Add filters.\n parameters.matchAll = [];\n liveDataQuery.filters.forEach(filter => {\n if (filter.matchAll) {\n parameters.matchAll.push(filter.property);\n }\n parameters['filters.' + filter.property] = filter.constraints\n .filter(constraint => constraint.value !== undefined)\n .map(constraint => constraint.operator + ':' + constraint.value);\n });\n // Add sort.\n parameters.sort = liveDataQuery.sort.map(sort => sort.property);\n parameters.descending = liveDataQuery.sort.map(sort => sort.descending);\n\n return Promise.resolve($.getJSON(entriesURL, $.param(parameters, true)).then(toLiveData));\n };\n\n var getEntriesURL = function(source) {\n var entriesURL = baseURL + encodeURIComponent(source.id) + '/entries';\n return addSourcePathParameters(source, entriesURL);\n };\n\n function addSourcePathParameters(source, url) {\n var parameters = {\n // Make sure the response is not retrieved from cache (IE11 doesn't obey the caching HTTP headers).\n timestamp: new Date().getTime(),\n namespace: `wiki:${XWiki.currentWiki}`\n };\n addSourceParameters(parameters, source);\n return `${url}?${$.param(parameters, true)}`;\n }\n\n function getEntryPropertyURL(source, entryId, propertyId) {\n const encodedSourceId = encodeURIComponent(source.id);\n const encodedEntryId = encodeURIComponent(entryId);\n const encodedPropertyId = encodeURIComponent(propertyId);\n const url = `${baseURL}${encodedSourceId}/entries/${encodedEntryId}/properties/${encodedPropertyId}`\n return addSourcePathParameters(source, url);\n }\n \n function getEntryURL(source, entryId) {\n const encodedSourceId = encodeURIComponent(source.id);\n const encodedEntryId = encodeURIComponent(entryId);\n const url = `${baseURL}${encodedSourceId}/entries/${encodedEntryId}`\n return addSourcePathParameters(source, url);\n }\n\n var addSourceParameters = function(parameters, source) {\n $.each(source, (key, value) => {\n if (key !== 'id') {\n parameters['sourceParams.' + key] = value;\n }\n });\n };\n\n var toLiveData = function(data) {\n return {\n count: data.count,\n entries: data.entries.map(entry => entry.values)\n };\n };\n\n var addEntry = function(source, entry) {\n return Promise.resolve($.post(getEntriesURL(source), entry).then(e => e.values));\n };\n \n function updateEntry(source, entryId, values) {\n return Promise.resolve($.ajax({\n type: 'PUT',\n url: getEntryURL(source, entryId),\n contentType: 'application/json',\n data: JSON.stringify({values})\n }));\n }\n\n var getTranslations = function(locale, prefix, keys) {\n const translationsURL = `${module.config().contextPath}/rest/wikis/${XWiki.currentWiki}/localization/translations`;\n return Promise.resolve($.getJSON(translationsURL, $.param({\n locale: locale,\n prefix: prefix,\n key: keys\n }, true)).then(toTranslationsMap));\n };\n\n var toTranslationsMap = function(responseJSON) {\n var translationsMap = {};\n responseJSON.translations?.forEach(translation => translationsMap[translation.key] = translation.rawSource);\n return translationsMap;\n };\n\n function updateEntryProperty(source, entryId, propertyId, propertyValue) {\n return Promise.resolve($.ajax({\n type: 'PUT',\n url: getEntryPropertyURL(source, entryId, propertyId),\n contentType: 'text/plain',\n data: `${propertyValue}`\n }))\n }\n\n return {\n getEntries,\n addEntry,\n updateEntry, \n updateEntryProperty,\n getTranslations\n };\n});\n","/*\n * See the NOTICE file distributed with this work for additional\n * information regarding copyright ownership.\n *\n * This is free software; you can redistribute it and/or modify it\n * under the terms of the GNU Lesser General Public License as\n * published by the Free Software Foundation; either version 2.1 of\n * the License, or (at your option) any later version.\n *\n * This software is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n * Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public\n * License along with this software; if not, write to the Free\n * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n * 02110-1301 USA, or see the FSF site: http://www.fsf.org.\n */\n\n/**\n * Polyfills that are not yet provided by Closure Compiler.\n * See https://github.com/google/closure-compiler/blob/master/src/com/google/javascript/jscomp/js/polyfills.txt\n */\ndefine('xwiki-livedata-polyfills', function () {\n /**\n * Polyfill for the custom event function for IE 11\n * Taken from https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent/CustomEvent\n */\n (function () {\n if (typeof window.CustomEvent === \"function\") return false;\n function CustomEvent (event, params) {\n params = params || {bubbles: false, cancelable: false, detail: null};\n var evt = document.createEvent('CustomEvent');\n evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail);\n return evt;\n }\n window.CustomEvent = CustomEvent;\n })();\n});\n"], "names":["define","Vue","VueI18n","XWikiLivedata","liveDataSource","jsonMerge","editBus","use","instancesMap","WeakMap","FootnotesService","constructor","_footnotes","put","symbol","translationKey","some","footnote","push","reset","splice","list","Logic","element","data","JSON","parse","getAttribute","entries","Object","freeze","firstEntriesLoading","currentLayoutId","changeLayout","meta","defaultLayout","entrySelection","selected","deselected","isGlobal","openedPanels","footnotes","removeAttribute","locale","document","documentElement","i18n","messages","silentFallbackWarn","vue","el","components","template","logic","length","updateEntries","finally","init","loadTranslations","this.loadTranslations","componentName","prefix","keys","translations","error","getTranslations","mergeLocaleMessage","console","translationsPromise","translate","this.translate","key","args","$t","translationsLoaded","this.translationsLoaded","prototype","triggerEvent","eventName","eventData","defaultData","livedata","bubbles","detail","assign","event","CustomEvent","dispatchEvent","onEvent","callback","addEventListener","e","onEventWhere","condition","isDetailMatching","every","is","getLayoutIds","layouts","map","layoutDescriptor","id","getEntryId","entry","idProperty","entryDescriptor","undefined","warn","uniqueArrayHas","uniqueArray","item","includes","uniqueArrayAdd","uniqueArrayRemove","index","indexOf","uniqueArrayToggle","force","getPropertyDescriptors","query","properties","propertyId","getPropertyDescriptor","propertyDescriptor","propertyDescriptors","find","getPropertyTypeDescriptor","propertyTypes","typeDescriptor","type","getLayoutDescriptor","layoutId","getDisplayerDescriptor","customDisplayerDescriptor","displayerId","defaultDisplayer","defaultDisplayerDescriptor","displayers","displayer","getFilterDescriptor","customFilterDescriptor","filterId","defaultFilter","defaultFilterDescriptor","filters","filter","fetchEntries","getEntries","then","catch","err","readyState","value","XWiki","widgets","Notification","isEditable","actions","action","isEntryEditable","isPropertyEditable","isActionAllowed","propertyTypeDescriptor","editable","setValue","source","entryId","updateEntryProperty","setValues","updateEntry","values","canAddEntry","addEntry","Promise","resolve","slice","newEntry","count","previousLayoutId","getPageCount","Math","ceil","limit","getPageIndex","entryIndex","offset","floor","setPageIndex","pageIndex","reject","previousPageIndex","getFirstIndexOfPage","getLastIndexOfPage","min","setPageSize","pageSize","previousPageSize","isPropertyVisible","visible","setPropertyVisible","reorderProperty","from","toIndex","fromIndex","isSelectionEnabled","selection","enabled","isEntrySelected","selectEntries","entryArray","Array","forEach","deselectEntries","toggleSelectEntries","select","selectableCountInPage","setEntrySelectGlobal","global","state","getActionDescriptor","descriptor","baseDescriptor","actionDescriptor","allowProperty","isPropertySortable","sortable","getSortableProperties","property","getUnsortedProperties","getQuerySort","sort","level","descending","Error","currentLevel","findIndex","sortObject","addSort","propertyQuerySort","removeSort","reorderSort","querySort","isPropertyFilterable","filterable","getFilterableProperties","getUnfilteredProperties","getQueryFilterGroup","constraints","getQueryFilters","queryFilterGroup","getFilterDefaultOperator","filterDescriptor","filterOperators","operators","defaultOperator","isDefaultOperatorValid","operator","_computeFilterEntries","filterEntry","filterOperator","oldEntry","currentEntry","queryFilters","fromEntries","defaultEntry","self","newEntryValidOperator","_getFilteringType","queryFilter","filterEntries","filteringType","matchAll","removeAllFilters","addFilter","removeFilter","filterIndex","filterGroup","removedFilterGroups","removedFilters","getEditBus","has","set","get","$","xcontext","getPropertyReference","propertyName","className","startsWith","substring","load","mode","documentReference","targetUrl","Document","Model","EntityType","DOCUMENT","getURL","xpage","language","done","html","fail","edit","view","setLocalization","_logic","_editBus","_editBusService","EditBusService","editStates","$on","entryState","propertyState","editing","content","tosave","save","canBeSaved","keyEntry","entryValue","editStatesKey","editStateKey","editState","onAnyEvent","start","$emit","cancel","merge","left","right","mergeObject","isArray","mergeArray","stringify","fromRight","rightItem","findById","fromLeft","leftItem","concat","hasOwnProperty","array","objects","module","addSourcePathParameters","url","parameters","timestamp","Date","getTime","namespace","currentWiki","addSourceParameters","param","baseURL","config","contextPath","getEntriesURL","entriesURL","encodeURIComponent","each","toLiveData","toTranslationsMap","responseJSON","translationsMap","translation","rawSource","liveDataQuery","constraint","getJSON","post","ajax","encodedSourceId","encodedEntryId","contentType","propertyValue","encodedPropertyId","translationsURL","window","params","cancelable","evt","createEvent","initCustomEvent"] }