{"version":3,"sources":["license.js","loader.js","@glimmer/compiler.js","@glimmer/reference.js","@glimmer/syntax.js","@glimmer/util.js","@glimmer/wire-format.js","backburner.js","container.js","ember-babel.js","ember-console.js","ember-debug/deprecate.js","ember-debug/error.js","ember-debug/features.js","ember-debug/handlers.js","ember-debug/index.js","ember-debug/testing.js","ember-debug/warn.js","ember-environment.js","ember-metal.js","ember-template-compiler/compat.js","ember-template-compiler/index.js","ember-template-compiler/plugins/assert-input-helper-without-block.js","ember-template-compiler/plugins/assert-reserved-named-arguments.js","ember-template-compiler/plugins/deprecate-render-model.js","ember-template-compiler/plugins/deprecate-render.js","ember-template-compiler/plugins/extract-pragma-tag.js","ember-template-compiler/plugins/index.js","ember-template-compiler/plugins/transform-action-syntax.js","ember-template-compiler/plugins/transform-angle-bracket-components.js","ember-template-compiler/plugins/transform-attrs-into-args.js","ember-template-compiler/plugins/transform-dot-component-invocation.js","ember-template-compiler/plugins/transform-each-in-into-each.js","ember-template-compiler/plugins/transform-has-block-syntax.js","ember-template-compiler/plugins/transform-inline-link-to.js","ember-template-compiler/plugins/transform-input-on-to-onEvent.js","ember-template-compiler/plugins/transform-input-type-syntax.js","ember-template-compiler/plugins/transform-old-binding-syntax.js","ember-template-compiler/plugins/transform-old-class-binding-syntax.js","ember-template-compiler/plugins/transform-quoted-bindings-into-just-bindings.js","ember-template-compiler/plugins/transform-top-level-components.js","ember-template-compiler/system/bootstrap.js","ember-template-compiler/system/calculate-location-display.js","ember-template-compiler/system/compile-options.js","ember-template-compiler/system/compile.js","ember-template-compiler/system/precompile.js","ember-utils.js","ember/features.js","ember/version.js","handlebars.js","node-module.js","simple-html-tokenizer.js","bootstrap"],"sourcesContent":["/*!\n * @overview Ember - JavaScript Application Framework\n * @copyright Copyright 2011-2017 Tilde Inc. and contributors\n * Portions Copyright 2006-2011 Strobe Inc.\n * Portions Copyright 2008-2011 Apple Inc. All rights reserved.\n * @license Licensed under MIT license\n * See https://raw.github.com/emberjs/ember.js/master/LICENSE\n * @version 2.18.0\n */\n","/*global process */\nvar enifed, requireModule, Ember;\nvar mainContext = this; // Used in ember-environment/lib/global.js\n\n(function() {\n function missingModule(name, referrerName) {\n if (referrerName) {\n throw new Error('Could not find module ' + name + ' required by: ' + referrerName);\n } else {\n throw new Error('Could not find module ' + name);\n }\n }\n\n function internalRequire(_name, referrerName) {\n var name = _name;\n var mod = registry[name];\n\n if (!mod) {\n name = name + '/index';\n mod = registry[name];\n }\n\n var exports = seen[name];\n\n if (exports !== undefined) {\n return exports;\n }\n\n exports = seen[name] = {};\n\n if (!mod) {\n missingModule(_name, referrerName);\n }\n\n var deps = mod.deps;\n var callback = mod.callback;\n var reified = new Array(deps.length);\n\n for (var i = 0; i < deps.length; i++) {\n if (deps[i] === 'exports') {\n reified[i] = exports;\n } else if (deps[i] === 'require') {\n reified[i] = requireModule;\n } else {\n reified[i] = internalRequire(deps[i], name);\n }\n }\n\n callback.apply(this, reified);\n\n return exports;\n }\n\n var isNode = typeof window === 'undefined' &&\n typeof process !== 'undefined' && {}.toString.call(process) === '[object process]';\n\n if (!isNode) {\n Ember = this.Ember = this.Ember || {};\n }\n\n if (typeof Ember === 'undefined') { Ember = {}; }\n\n if (typeof Ember.__loader === 'undefined') {\n var registry = {};\n var seen = {};\n\n enifed = function(name, deps, callback) {\n var value = { };\n\n if (!callback) {\n value.deps = [];\n value.callback = deps;\n } else {\n value.deps = deps;\n value.callback = callback;\n }\n\n registry[name] = value;\n };\n\n requireModule = function(name) {\n return internalRequire(name, null);\n };\n\n // setup `require` module\n requireModule['default'] = requireModule;\n\n requireModule.has = function registryHas(moduleName) {\n return !!registry[moduleName] || !!registry[moduleName + '/index'];\n };\n\n requireModule._eak_seen = registry;\n\n Ember.__loader = {\n define: enifed,\n require: requireModule,\n registry: registry\n };\n } else {\n enifed = Ember.__loader.define;\n requireModule = Ember.__loader.require;\n }\n})();\n","enifed('@glimmer/compiler', ['exports', 'node-module', '@glimmer/syntax', '@glimmer/util', '@glimmer/wire-format'], function (exports, _nodeModule, _syntax, _util, _wireFormat) {\n 'use strict';\n\n exports.TemplateVisitor = exports.precompile = undefined;\n\n var _createClass$1 = function () {\n function defineProperties(target, props) {\n var i, descriptor;\n\n for (i = 0; i < props.length; i++) {\n descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;descriptor.configurable = true;if (\"value\" in descriptor) descriptor.writable = true;Object.defineProperty(target, descriptor.key, descriptor);\n }\n }return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);if (staticProps) defineProperties(Constructor, staticProps);return Constructor;\n };\n }();\n\n function _defaults(obj, defaults) {\n var keys = Object.getOwnPropertyNames(defaults),\n i,\n key,\n value;for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = Object.getOwnPropertyDescriptor(defaults, key);\n if (value && value.configurable && obj[key] === undefined) {\n Object.defineProperty(obj, key, value);\n }\n }return obj;\n }\n\n function _possibleConstructorReturn(self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n }\n\n function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } });if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : _defaults(subClass, superClass);\n }\n\n function _classCallCheck$1(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var SymbolTable = function () {\n function SymbolTable() {\n _classCallCheck$1(this, SymbolTable);\n }\n\n SymbolTable.top = function () {\n return new ProgramSymbolTable();\n };\n\n SymbolTable.prototype.child = function (locals) {\n var _this = this;\n\n var symbols = locals.map(function (name) {\n return _this.allocate(name);\n });\n return new BlockSymbolTable(this, locals, symbols);\n };\n\n return SymbolTable;\n }();\n var ProgramSymbolTable = function (_SymbolTable) {\n _inherits(ProgramSymbolTable, _SymbolTable);\n\n function ProgramSymbolTable() {\n _classCallCheck$1(this, ProgramSymbolTable);\n\n var _this2 = _possibleConstructorReturn(this, _SymbolTable.apply(this, arguments));\n\n _this2.symbols = [];\n _this2.size = 1;\n _this2.named = (0, _util.dict)();\n _this2.blocks = (0, _util.dict)();\n return _this2;\n }\n\n ProgramSymbolTable.prototype.has = function () {\n return false;\n };\n\n ProgramSymbolTable.prototype.get = function () {\n throw (0, _util.unreachable)();\n };\n\n ProgramSymbolTable.prototype.getLocalsMap = function () {\n return {};\n };\n\n ProgramSymbolTable.prototype.getEvalInfo = function () {\n return [];\n };\n\n ProgramSymbolTable.prototype.allocateNamed = function (name) {\n var named = this.named[name];\n if (!named) {\n named = this.named[name] = this.allocate('@' + name);\n }\n return named;\n };\n\n ProgramSymbolTable.prototype.allocateBlock = function (name) {\n var block = this.blocks[name];\n if (!block) {\n block = this.blocks[name] = this.allocate('&' + name);\n }\n return block;\n };\n\n ProgramSymbolTable.prototype.allocate = function (identifier) {\n this.symbols.push(identifier);\n return this.size++;\n };\n\n return ProgramSymbolTable;\n }(SymbolTable);\n var BlockSymbolTable = function (_SymbolTable2) {\n _inherits(BlockSymbolTable, _SymbolTable2);\n\n function BlockSymbolTable(parent, symbols, slots) {\n _classCallCheck$1(this, BlockSymbolTable);\n\n var _this3 = _possibleConstructorReturn(this, _SymbolTable2.call(this));\n\n _this3.parent = parent;\n _this3.symbols = symbols;\n _this3.slots = slots;\n return _this3;\n }\n\n BlockSymbolTable.prototype.has = function (name) {\n return this.symbols.indexOf(name) !== -1 || this.parent.has(name);\n };\n\n BlockSymbolTable.prototype.get = function (name) {\n var slot = this.symbols.indexOf(name);\n return slot === -1 ? this.parent.get(name) : this.slots[slot];\n };\n\n BlockSymbolTable.prototype.getLocalsMap = function () {\n var _this4 = this;\n\n var dict$$1 = this.parent.getLocalsMap();\n this.symbols.forEach(function (symbol) {\n return dict$$1[symbol] = _this4.get(symbol);\n });\n return dict$$1;\n };\n\n BlockSymbolTable.prototype.getEvalInfo = function () {\n var locals = this.getLocalsMap();\n return Object.keys(locals).map(function (symbol) {\n return locals[symbol];\n });\n };\n\n BlockSymbolTable.prototype.allocateNamed = function (name) {\n return this.parent.allocateNamed(name);\n };\n\n BlockSymbolTable.prototype.allocateBlock = function (name) {\n return this.parent.allocateBlock(name);\n };\n\n BlockSymbolTable.prototype.allocate = function (identifier) {\n return this.parent.allocate(identifier);\n };\n\n return BlockSymbolTable;\n }(SymbolTable);\n /**\n * Takes in an AST and outputs a list of actions to be consumed\n * by a compiler. For example, the template\n *\n * foo{{bar}}
baz
\n *\n * produces the actions\n *\n * [['startProgram', [programNode, 0]],\n * ['text', [textNode, 0, 3]],\n * ['mustache', [mustacheNode, 1, 3]],\n * ['openElement', [elementNode, 2, 3, 0]],\n * ['text', [textNode, 0, 1]],\n * ['closeElement', [elementNode, 2, 3],\n * ['endProgram', [programNode]]]\n *\n * This visitor walks the AST depth first and backwards. As\n * a result the bottom-most child template will appear at the\n * top of the actions list whereas the root template will appear\n * at the bottom of the list. For example,\n *\n *
{{#if}}foo{{else}}bar{{/if}}
\n *\n * produces the actions\n *\n * [['startProgram', [programNode, 0]],\n * ['text', [textNode, 0, 2, 0]],\n * ['openElement', [elementNode, 1, 2, 0]],\n * ['closeElement', [elementNode, 1, 2]],\n * ['endProgram', [programNode]],\n * ['startProgram', [programNode, 0]],\n * ['text', [textNode, 0, 1]],\n * ['endProgram', [programNode]],\n * ['startProgram', [programNode, 2]],\n * ['openElement', [elementNode, 0, 1, 1]],\n * ['block', [blockNode, 0, 1]],\n * ['closeElement', [elementNode, 0, 1]],\n * ['endProgram', [programNode]]]\n *\n * The state of the traversal is maintained by a stack of frames.\n * Whenever a node with children is entered (either a ProgramNode\n * or an ElementNode) a frame is pushed onto the stack. The frame\n * contains information about the state of the traversal of that\n * node. For example,\n *\n * - index of the current child node being visited\n * - the number of mustaches contained within its child nodes\n * - the list of actions generated by its child nodes\n */\n\n var Frame = function Frame() {\n _classCallCheck$1(this, Frame);\n\n this.parentNode = null;\n this.children = null;\n this.childIndex = null;\n this.childCount = null;\n this.childTemplateCount = 0;\n this.mustacheCount = 0;\n this.actions = [];\n this.blankChildTextNodes = null;\n this.symbols = null;\n };\n\n var TemplateVisitor = function () {\n function TemplateVisitor() {\n _classCallCheck$1(this, TemplateVisitor);\n\n this.frameStack = [];\n this.actions = [];\n this.programDepth = -1;\n }\n\n TemplateVisitor.prototype.visit = function (node) {\n this[node.type](node);\n };\n // Traversal methods\n\n\n TemplateVisitor.prototype.Program = function (program) {\n var _actions, i;\n\n this.programDepth++;\n var parentFrame = this.getCurrentFrame();\n var programFrame = this.pushFrame();\n if (!parentFrame) {\n program['symbols'] = SymbolTable.top();\n } else {\n program['symbols'] = parentFrame.symbols.child(program.blockParams);\n }\n var startType = void 0,\n endType = void 0;\n if (this.programDepth === 0) {\n startType = 'startProgram';\n endType = 'endProgram';\n } else {\n startType = 'startBlock';\n endType = 'endBlock';\n }\n programFrame.parentNode = program;\n programFrame.children = program.body;\n programFrame.childCount = program.body.length;\n programFrame.blankChildTextNodes = [];\n programFrame.actions.push([endType, [program, this.programDepth]]);\n programFrame.symbols = program['symbols'];\n for (i = program.body.length - 1; i >= 0; i--) {\n programFrame.childIndex = i;\n this.visit(program.body[i]);\n }\n programFrame.actions.push([startType, [program, programFrame.childTemplateCount, programFrame.blankChildTextNodes.reverse()]]);\n this.popFrame();\n this.programDepth--;\n // Push the completed template into the global actions list\n if (parentFrame) {\n parentFrame.childTemplateCount++;\n }\n (_actions = this.actions).push.apply(_actions, programFrame.actions.reverse());\n };\n\n TemplateVisitor.prototype.ElementNode = function (element) {\n var _parentFrame$actions, i, _i;\n\n var parentFrame = this.currentFrame;\n var elementFrame = this.pushFrame();\n elementFrame.parentNode = element;\n elementFrame.children = element.children;\n elementFrame.childCount = element.children.length;\n elementFrame.mustacheCount += element.modifiers.length;\n elementFrame.blankChildTextNodes = [];\n elementFrame.symbols = element['symbols'] = parentFrame.symbols.child(element.blockParams);\n var actionArgs = [element, parentFrame.childIndex, parentFrame.childCount];\n elementFrame.actions.push(['closeElement', actionArgs]);\n for (i = element.attributes.length - 1; i >= 0; i--) {\n this.visit(element.attributes[i]);\n }\n for (_i = element.children.length - 1; _i >= 0; _i--) {\n elementFrame.childIndex = _i;\n this.visit(element.children[_i]);\n }\n var open = ['openElement', [].concat(actionArgs, [elementFrame.mustacheCount, elementFrame.blankChildTextNodes.reverse()])];\n elementFrame.actions.push(open);\n this.popFrame();\n // Propagate the element's frame state to the parent frame\n if (elementFrame.mustacheCount > 0) {\n parentFrame.mustacheCount++;\n }\n parentFrame.childTemplateCount += elementFrame.childTemplateCount;\n (_parentFrame$actions = parentFrame.actions).push.apply(_parentFrame$actions, elementFrame.actions);\n };\n\n TemplateVisitor.prototype.AttrNode = function (attr) {\n if (attr.value.type !== 'TextNode') {\n this.currentFrame.mustacheCount++;\n }\n };\n\n TemplateVisitor.prototype.TextNode = function (text) {\n var frame = this.currentFrame;\n if (text.chars === '') {\n frame.blankChildTextNodes.push(domIndexOf(frame.children, text));\n }\n frame.actions.push(['text', [text, frame.childIndex, frame.childCount]]);\n };\n\n TemplateVisitor.prototype.BlockStatement = function (node) {\n var frame = this.currentFrame;\n frame.mustacheCount++;\n frame.actions.push(['block', [node, frame.childIndex, frame.childCount]]);\n if (node.inverse) {\n this.visit(node.inverse);\n }\n if (node.program) {\n this.visit(node.program);\n }\n };\n\n TemplateVisitor.prototype.PartialStatement = function (node) {\n var frame = this.currentFrame;\n frame.mustacheCount++;\n frame.actions.push(['mustache', [node, frame.childIndex, frame.childCount]]);\n };\n\n TemplateVisitor.prototype.CommentStatement = function (text) {\n var frame = this.currentFrame;\n frame.actions.push(['comment', [text, frame.childIndex, frame.childCount]]);\n };\n\n TemplateVisitor.prototype.MustacheCommentStatement = function () {\n // Intentional empty: Handlebars comments should not affect output.\n };\n\n TemplateVisitor.prototype.MustacheStatement = function (mustache) {\n var frame = this.currentFrame;\n frame.mustacheCount++;\n frame.actions.push(['mustache', [mustache, frame.childIndex, frame.childCount]]);\n };\n\n // Frame helpers\n\n\n TemplateVisitor.prototype.getCurrentFrame = function () {\n return this.frameStack[this.frameStack.length - 1];\n };\n\n TemplateVisitor.prototype.pushFrame = function () {\n var frame = new Frame();\n this.frameStack.push(frame);\n return frame;\n };\n\n TemplateVisitor.prototype.popFrame = function () {\n return this.frameStack.pop();\n };\n\n _createClass$1(TemplateVisitor, [{\n key: 'currentFrame',\n get: function () {\n return this.getCurrentFrame();\n }\n }]);\n\n return TemplateVisitor;\n }();\n function domIndexOf(nodes, domNode) {\n var index = -1,\n i,\n node;\n for (i = 0; i < nodes.length; i++) {\n node = nodes[i];\n\n if (node.type !== 'TextNode' && node.type !== 'ElementNode') {\n continue;\n } else {\n index++;\n }\n if (node === domNode) {\n return index;\n }\n }\n return -1;\n }\n\n var _createClass$2 = function () {\n function defineProperties(target, props) {\n var i, descriptor;\n\n for (i = 0; i < props.length; i++) {\n descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;descriptor.configurable = true;if (\"value\" in descriptor) descriptor.writable = true;Object.defineProperty(target, descriptor.key, descriptor);\n }\n }return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);if (staticProps) defineProperties(Constructor, staticProps);return Constructor;\n };\n }();\n\n function _defaults$1(obj, defaults) {\n var keys = Object.getOwnPropertyNames(defaults),\n i,\n key,\n value;for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = Object.getOwnPropertyDescriptor(defaults, key);\n if (value && value.configurable && obj[key] === undefined) {\n Object.defineProperty(obj, key, value);\n }\n }return obj;\n }\n\n function _possibleConstructorReturn$1(self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n }\n\n function _inherits$1(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } });if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : _defaults$1(subClass, superClass);\n }\n\n function _classCallCheck$2(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var Block = function () {\n function Block() {\n _classCallCheck$2(this, Block);\n\n this.statements = [];\n }\n\n Block.prototype.push = function (statement) {\n this.statements.push(statement);\n };\n\n return Block;\n }();\n var InlineBlock = function (_Block) {\n _inherits$1(InlineBlock, _Block);\n\n function InlineBlock(table) {\n _classCallCheck$2(this, InlineBlock);\n\n var _this = _possibleConstructorReturn$1(this, _Block.call(this));\n\n _this.table = table;\n return _this;\n }\n\n InlineBlock.prototype.toJSON = function () {\n return {\n statements: this.statements,\n parameters: this.table.slots\n };\n };\n\n return InlineBlock;\n }(Block);\n var TemplateBlock = function (_Block2) {\n _inherits$1(TemplateBlock, _Block2);\n\n function TemplateBlock(symbolTable) {\n _classCallCheck$2(this, TemplateBlock);\n\n var _this2 = _possibleConstructorReturn$1(this, _Block2.call(this));\n\n _this2.symbolTable = symbolTable;\n _this2.type = \"template\";\n _this2.yields = new _util.DictSet();\n _this2.named = new _util.DictSet();\n _this2.blocks = [];\n _this2.hasEval = false;\n return _this2;\n }\n\n TemplateBlock.prototype.push = function (statement) {\n this.statements.push(statement);\n };\n\n TemplateBlock.prototype.toJSON = function () {\n return {\n symbols: this.symbolTable.symbols,\n statements: this.statements,\n hasEval: this.hasEval\n };\n };\n\n return TemplateBlock;\n }(Block);\n var ComponentBlock = function (_Block3) {\n _inherits$1(ComponentBlock, _Block3);\n\n function ComponentBlock(table) {\n _classCallCheck$2(this, ComponentBlock);\n\n var _this3 = _possibleConstructorReturn$1(this, _Block3.call(this));\n\n _this3.table = table;\n _this3.attributes = [];\n _this3.arguments = [];\n _this3.inParams = true;\n _this3.positionals = [];\n return _this3;\n }\n\n ComponentBlock.prototype.push = function (statement) {\n if (this.inParams) {\n if (_wireFormat.Statements.isFlushElement(statement)) {\n this.inParams = false;\n } else if (_wireFormat.Statements.isArgument(statement)) {\n this.arguments.push(statement);\n } else if (_wireFormat.Statements.isAttribute(statement)) {\n this.attributes.push(statement);\n } else if (_wireFormat.Statements.isModifier(statement)) {\n throw new Error('Compile Error: Element modifiers are not allowed in components');\n } else {\n throw new Error('Compile Error: only parameters allowed before flush-element');\n }\n } else {\n this.statements.push(statement);\n }\n };\n\n ComponentBlock.prototype.toJSON = function () {\n var args = this.arguments;\n var keys = args.map(function (arg) {\n return arg[1];\n });\n var values = args.map(function (arg) {\n return arg[2];\n });\n return [this.attributes, [keys, values], {\n statements: this.statements,\n parameters: this.table.slots\n }];\n };\n\n return ComponentBlock;\n }(Block);\n var Template = function () {\n function Template(symbols, meta) {\n _classCallCheck$2(this, Template);\n\n this.meta = meta;\n this.block = new TemplateBlock(symbols);\n }\n\n Template.prototype.toJSON = function () {\n return {\n block: this.block.toJSON(),\n meta: this.meta\n };\n };\n\n return Template;\n }();\n\n var JavaScriptCompiler = function () {\n function JavaScriptCompiler(opcodes, symbols, meta) {\n _classCallCheck$2(this, JavaScriptCompiler);\n\n this.blocks = new _util.Stack();\n this.values = [];\n this.opcodes = opcodes;\n this.template = new Template(symbols, meta);\n }\n\n JavaScriptCompiler.process = function (opcodes, symbols, meta) {\n var compiler = new JavaScriptCompiler(opcodes, symbols, meta);\n return compiler.process();\n };\n\n JavaScriptCompiler.prototype.process = function () {\n var _this4 = this;\n\n this.opcodes.forEach(function (_ref) {\n var opcode = _ref[0],\n args = _ref.slice(1);\n\n if (!_this4[opcode]) {\n throw new Error(\"unimplemented \" + opcode + \" on JavaScriptCompiler\");\n }\n _this4[opcode].apply(_this4, args);\n });\n return this.template;\n };\n /// Nesting\n\n\n JavaScriptCompiler.prototype.startBlock = function (_ref2) {\n var program = _ref2[0];\n\n var block = new InlineBlock(program['symbols']);\n this.blocks.push(block);\n };\n\n JavaScriptCompiler.prototype.endBlock = function () {\n var template = this.template,\n blocks = this.blocks;\n\n var block = blocks.pop();\n template.block.blocks.push(block.toJSON());\n };\n\n JavaScriptCompiler.prototype.startProgram = function () {\n this.blocks.push(this.template.block);\n };\n\n JavaScriptCompiler.prototype.endProgram = function () {};\n /// Statements\n\n\n JavaScriptCompiler.prototype.text = function (content) {\n this.push([_wireFormat.Ops.Text, content]);\n };\n\n JavaScriptCompiler.prototype.append = function (trusted) {\n this.push([_wireFormat.Ops.Append, this.popValue(), trusted]);\n };\n\n JavaScriptCompiler.prototype.comment = function (value) {\n this.push([_wireFormat.Ops.Comment, value]);\n };\n\n JavaScriptCompiler.prototype.modifier = function (name) {\n var params = this.popValue();\n var hash = this.popValue();\n this.push([_wireFormat.Ops.Modifier, name, params, hash]);\n };\n\n JavaScriptCompiler.prototype.block = function (name, template, inverse) {\n var params = this.popValue();\n var hash = this.popValue();\n var blocks = this.template.block.blocks;\n (0, _util.assert)(typeof template !== 'number' || blocks[template] !== null, 'missing block in the compiler');\n (0, _util.assert)(typeof inverse !== 'number' || blocks[inverse] !== null, 'missing block in the compiler');\n this.push([_wireFormat.Ops.Block, name, params, hash, blocks[template], blocks[inverse]]);\n };\n\n JavaScriptCompiler.prototype.openElement = function (element) {\n var tag = element.tag;\n if (tag.indexOf('-') !== -1) {\n this.startComponent(element);\n } else if (element.blockParams.length > 0) {\n throw new Error(\"Compile Error: <\" + element.tag + \"> is not a component and doesn't support block parameters\");\n } else {\n this.push([_wireFormat.Ops.OpenElement, tag]);\n }\n };\n\n JavaScriptCompiler.prototype.flushElement = function () {\n this.push([_wireFormat.Ops.FlushElement]);\n };\n\n JavaScriptCompiler.prototype.closeElement = function (element) {\n var tag = element.tag,\n _endComponent,\n attrs,\n args,\n block;\n if (tag.indexOf('-') !== -1) {\n _endComponent = this.endComponent(), attrs = _endComponent[0], args = _endComponent[1], block = _endComponent[2];\n\n\n this.push([_wireFormat.Ops.Component, tag, attrs, args, block]);\n } else {\n this.push([_wireFormat.Ops.CloseElement]);\n }\n };\n\n JavaScriptCompiler.prototype.staticAttr = function (name, namespace) {\n var value = this.popValue();\n this.push([_wireFormat.Ops.StaticAttr, name, value, namespace]);\n };\n\n JavaScriptCompiler.prototype.dynamicAttr = function (name, namespace) {\n var value = this.popValue();\n this.push([_wireFormat.Ops.DynamicAttr, name, value, namespace]);\n };\n\n JavaScriptCompiler.prototype.trustingAttr = function (name, namespace) {\n var value = this.popValue();\n this.push([_wireFormat.Ops.TrustingAttr, name, value, namespace]);\n };\n\n JavaScriptCompiler.prototype.staticArg = function (name) {\n var value = this.popValue();\n this.push([_wireFormat.Ops.StaticArg, name, value]);\n };\n\n JavaScriptCompiler.prototype.dynamicArg = function (name) {\n var value = this.popValue();\n this.push([_wireFormat.Ops.DynamicArg, name, value]);\n };\n\n JavaScriptCompiler.prototype.yield = function (to) {\n var params = this.popValue();\n this.push([_wireFormat.Ops.Yield, to, params]);\n };\n\n JavaScriptCompiler.prototype.debugger = function (evalInfo) {\n this.push([_wireFormat.Ops.Debugger, evalInfo]);\n this.template.block.hasEval = true;\n };\n\n JavaScriptCompiler.prototype.hasBlock = function (name) {\n this.pushValue([_wireFormat.Ops.HasBlock, name]);\n };\n\n JavaScriptCompiler.prototype.hasBlockParams = function (name) {\n this.pushValue([_wireFormat.Ops.HasBlockParams, name]);\n };\n\n JavaScriptCompiler.prototype.partial = function (evalInfo) {\n var params = this.popValue();\n this.push([_wireFormat.Ops.Partial, params[0], evalInfo]);\n this.template.block.hasEval = true;\n };\n /// Expressions\n\n\n JavaScriptCompiler.prototype.literal = function (value) {\n if (value === undefined) {\n this.pushValue([_wireFormat.Ops.Undefined]);\n } else {\n this.pushValue(value);\n }\n };\n\n JavaScriptCompiler.prototype.unknown = function (name) {\n this.pushValue([_wireFormat.Ops.Unknown, name]);\n };\n\n JavaScriptCompiler.prototype.get = function (head, path) {\n this.pushValue([_wireFormat.Ops.Get, head, path]);\n };\n\n JavaScriptCompiler.prototype.maybeLocal = function (path) {\n this.pushValue([_wireFormat.Ops.MaybeLocal, path]);\n };\n\n JavaScriptCompiler.prototype.concat = function () {\n this.pushValue([_wireFormat.Ops.Concat, this.popValue()]);\n };\n\n JavaScriptCompiler.prototype.helper = function (name) {\n var params = this.popValue();\n var hash = this.popValue();\n this.pushValue([_wireFormat.Ops.Helper, name, params, hash]);\n };\n /// Stack Management Opcodes\n\n\n JavaScriptCompiler.prototype.startComponent = function (element) {\n var component = new ComponentBlock(element['symbols']);\n this.blocks.push(component);\n };\n\n JavaScriptCompiler.prototype.endComponent = function () {\n var component = this.blocks.pop();\n (0, _util.assert)(component instanceof ComponentBlock, \"Compiler bug: endComponent() should end a component\");\n return component.toJSON();\n };\n\n JavaScriptCompiler.prototype.prepareArray = function (size) {\n var values = [],\n i;\n for (i = 0; i < size; i++) {\n values.push(this.popValue());\n }\n this.pushValue(values);\n };\n\n JavaScriptCompiler.prototype.prepareObject = function (size) {\n (0, _util.assert)(this.values.length >= size, \"Expected \" + size + \" values on the stack, found \" + this.values.length);\n var keys = new Array(size),\n i;\n var values = new Array(size);\n for (i = 0; i < size; i++) {\n keys[i] = this.popValue();\n values[i] = this.popValue();\n }\n this.pushValue([keys, values]);\n };\n /// Utilities\n\n\n JavaScriptCompiler.prototype.push = function (args) {\n while (args[args.length - 1] === null) {\n args.pop();\n }\n this.currentBlock.push(args);\n };\n\n JavaScriptCompiler.prototype.pushValue = function (val) {\n this.values.push(val);\n };\n\n JavaScriptCompiler.prototype.popValue = function () {\n (0, _util.assert)(this.values.length, \"No expression found on stack\");\n return this.values.pop();\n };\n\n _createClass$2(JavaScriptCompiler, [{\n key: \"currentBlock\",\n get: function () {\n return this.blocks.current;\n }\n }]);\n\n return JavaScriptCompiler;\n }();\n\n var _createClass = function () {\n function defineProperties(target, props) {\n var i, descriptor;\n\n for (i = 0; i < props.length; i++) {\n descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;descriptor.configurable = true;if (\"value\" in descriptor) descriptor.writable = true;Object.defineProperty(target, descriptor.key, descriptor);\n }\n }return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);if (staticProps) defineProperties(Constructor, staticProps);return Constructor;\n };\n }();\n\n function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n function isTrustedValue(value) {\n return value.escaped !== undefined && !value.escaped;\n }\n\n var TemplateCompiler = function () {\n function TemplateCompiler(options) {\n _classCallCheck(this, TemplateCompiler);\n\n this.templateId = 0;\n this.templateIds = [];\n this.symbolStack = new _util.Stack();\n this.opcodes = [];\n this.includeMeta = false;\n this.options = options || {};\n }\n\n TemplateCompiler.compile = function (options, ast) {\n var templateVisitor = new TemplateVisitor();\n templateVisitor.visit(ast);\n var compiler = new TemplateCompiler(options);\n var opcodes = compiler.process(templateVisitor.actions);\n return JavaScriptCompiler.process(opcodes, ast['symbols'], options.meta);\n };\n\n TemplateCompiler.prototype.process = function (actions) {\n var _this = this;\n\n actions.forEach(function (_ref) {\n var name = _ref[0],\n args = _ref.slice(1);\n\n if (!_this[name]) {\n throw new Error(\"Unimplemented \" + name + \" on TemplateCompiler\");\n }\n _this[name].apply(_this, args);\n });\n return this.opcodes;\n };\n\n TemplateCompiler.prototype.startProgram = function (program) {\n this.symbolStack.push(program[0]['symbols']);\n this.opcode('startProgram', program, program);\n };\n\n TemplateCompiler.prototype.endProgram = function () {\n this.symbolStack.pop();\n this.opcode('endProgram', null);\n };\n\n TemplateCompiler.prototype.startBlock = function (program) {\n this.symbolStack.push(program[0]['symbols']);\n this.templateId++;\n this.opcode('startBlock', program, program);\n };\n\n TemplateCompiler.prototype.endBlock = function () {\n this.symbolStack.pop();\n this.templateIds.push(this.templateId - 1);\n this.opcode('endBlock', null);\n };\n\n TemplateCompiler.prototype.text = function (_ref2) {\n var action = _ref2[0];\n\n this.opcode('text', action, action.chars);\n };\n\n TemplateCompiler.prototype.comment = function (_ref3) {\n var action = _ref3[0];\n\n this.opcode('comment', action, action.value);\n };\n\n TemplateCompiler.prototype.openElement = function (_ref4) {\n var action = _ref4[0],\n i,\n _i;\n\n this.opcode('openElement', action, action);\n for (i = 0; i < action.attributes.length; i++) {\n this.attribute([action.attributes[i]]);\n }\n for (_i = 0; _i < action.modifiers.length; _i++) {\n this.modifier([action.modifiers[_i]]);\n }\n this.opcode('flushElement', null);\n this.symbolStack.push(action['symbols']);\n };\n\n TemplateCompiler.prototype.closeElement = function (_ref5) {\n var action = _ref5[0];\n\n this.symbolStack.pop();\n this.opcode('closeElement', null, action);\n };\n\n TemplateCompiler.prototype.attribute = function (_ref6) {\n var action = _ref6[0],\n isTrusting;\n var name = action.name,\n value = action.value;\n\n var namespace = (0, _util.getAttrNamespace)(name);\n var isStatic = this.prepareAttributeValue(value);\n if (name.charAt(0) === '@') {\n // Arguments\n if (isStatic) {\n this.opcode('staticArg', action, name);\n } else if (action.value.type === 'MustacheStatement') {\n this.opcode('dynamicArg', action, name);\n } else {\n this.opcode('dynamicArg', action, name);\n }\n } else {\n isTrusting = isTrustedValue(value);\n\n if (isStatic) {\n this.opcode('staticAttr', action, name, namespace);\n } else if (isTrusting) {\n this.opcode('trustingAttr', action, name, namespace);\n } else if (action.value.type === 'MustacheStatement') {\n this.opcode('dynamicAttr', action, name);\n } else {\n this.opcode('dynamicAttr', action, name, namespace);\n }\n }\n };\n\n TemplateCompiler.prototype.modifier = function (_ref7) {\n var action = _ref7[0];\n\n assertIsSimplePath(action.path, action.loc, 'modifier');\n var parts = action.path.parts;\n\n this.prepareHelper(action);\n this.opcode('modifier', action, parts[0]);\n };\n\n TemplateCompiler.prototype.mustache = function (_ref8) {\n var action = _ref8[0],\n to,\n params;\n var path = action.path;\n\n if ((0, _syntax.isLiteral)(path)) {\n this.mustacheExpression(action);\n this.opcode('append', action, !action.escaped);\n } else if (isYield(path)) {\n to = assertValidYield(action);\n\n this.yield(to, action);\n } else if (isPartial(path)) {\n params = assertValidPartial(action);\n\n this.partial(params, action);\n } else if (isDebugger(path)) {\n assertValidDebuggerUsage(action);\n this.debugger('debugger', action);\n } else {\n this.mustacheExpression(action);\n this.opcode('append', action, !action.escaped);\n }\n };\n\n TemplateCompiler.prototype.block = function (_ref9) {\n var action /*, index, count*/ = _ref9[0];\n\n this.prepareHelper(action);\n var templateId = this.templateIds.pop();\n var inverseId = action.inverse === null ? null : this.templateIds.pop();\n this.opcode('block', action, action.path.parts[0], templateId, inverseId);\n };\n /// Internal actions, not found in the original processed actions\n\n\n TemplateCompiler.prototype.arg = function (_ref10) {\n var path = _ref10[0];\n\n var _path$parts = path.parts,\n head = _path$parts[0],\n rest = _path$parts.slice(1);\n\n var symbol = this.symbols.allocateNamed(head);\n this.opcode('get', path, symbol, rest);\n };\n\n TemplateCompiler.prototype.mustacheExpression = function (expr) {\n var path = expr.path,\n _path$parts2,\n head,\n parts;\n\n if ((0, _syntax.isLiteral)(path)) {\n this.opcode('literal', expr, path.value);\n } else if (isBuiltInHelper(path)) {\n this.builtInHelper(expr);\n } else if (isArg(path)) {\n this.arg([path]);\n } else if (isHelperInvocation(expr)) {\n this.prepareHelper(expr);\n this.opcode('helper', expr, path.parts[0]);\n } else if (path.this) {\n this.opcode('get', expr, 0, path.parts);\n } else if (isLocal(path, this.symbols)) {\n _path$parts2 = path.parts, head = _path$parts2[0], parts = _path$parts2.slice(1);\n\n\n this.opcode('get', expr, this.symbols.get(head), parts);\n } else if (isSimplePath(path)) {\n this.opcode('unknown', expr, path.parts[0]);\n } else {\n this.opcode('maybeLocal', expr, path.parts);\n }\n };\n /// Internal Syntax\n\n\n TemplateCompiler.prototype.yield = function (to, action) {\n this.prepareParams(action.params);\n this.opcode('yield', action, this.symbols.allocateBlock(to));\n };\n\n TemplateCompiler.prototype.debugger = function (_name, action) {\n this.opcode('debugger', action, this.symbols.getEvalInfo());\n };\n\n TemplateCompiler.prototype.hasBlock = function (name, action) {\n this.opcode('hasBlock', action, this.symbols.allocateBlock(name));\n };\n\n TemplateCompiler.prototype.hasBlockParams = function (name, action) {\n this.opcode('hasBlockParams', action, this.symbols.allocateBlock(name));\n };\n\n TemplateCompiler.prototype.partial = function (_params, action) {\n this.prepareParams(action.params);\n this.opcode('partial', action, this.symbols.getEvalInfo());\n };\n\n TemplateCompiler.prototype.builtInHelper = function (expr) {\n var path = expr.path,\n name,\n _name2;\n\n if (isHasBlock(path)) {\n name = assertValidHasBlockUsage(expr.path.original, expr);\n\n this.hasBlock(name, expr);\n } else if (isHasBlockParams(path)) {\n _name2 = assertValidHasBlockUsage(expr.path.original, expr);\n\n this.hasBlockParams(_name2, expr);\n }\n };\n /// Expressions, invoked recursively from prepareParams and prepareHash\n\n\n TemplateCompiler.prototype.SubExpression = function (expr) {\n if (isBuiltInHelper(expr.path)) {\n this.builtInHelper(expr);\n } else {\n this.prepareHelper(expr);\n this.opcode('helper', expr, expr.path.parts[0]);\n }\n };\n\n TemplateCompiler.prototype.PathExpression = function (expr) {\n var symbols, _expr$parts, head;\n\n if (expr.data) {\n this.arg([expr]);\n } else {\n symbols = this.symbols;\n _expr$parts = expr.parts, head = _expr$parts[0];\n\n\n if (expr.this) {\n this.opcode('get', expr, 0, expr.parts);\n } else if (symbols.has(head)) {\n this.opcode('get', expr, symbols.get(head), expr.parts.slice(1));\n } else {\n this.opcode('maybeLocal', expr, expr.parts);\n }\n }\n };\n\n TemplateCompiler.prototype.StringLiteral = function (action) {\n this.opcode('literal', null, action.value);\n };\n\n TemplateCompiler.prototype.BooleanLiteral = function (action) {\n this.opcode('literal', null, action.value);\n };\n\n TemplateCompiler.prototype.NumberLiteral = function (action) {\n this.opcode('literal', null, action.value);\n };\n\n TemplateCompiler.prototype.NullLiteral = function (action) {\n this.opcode('literal', null, action.value);\n };\n\n TemplateCompiler.prototype.UndefinedLiteral = function (action) {\n this.opcode('literal', null, action.value);\n };\n /// Utilities\n\n\n TemplateCompiler.prototype.opcode = function (name, action) {\n for (_len = arguments.length, args = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {\n args[_key - 2] = arguments[_key];\n }\n\n var opcode = [name].concat(args),\n _len,\n args,\n _key;\n if (this.includeMeta && action) {\n opcode.push(this.meta(action));\n }\n this.opcodes.push(opcode);\n };\n\n TemplateCompiler.prototype.prepareHelper = function (expr) {\n assertIsSimplePath(expr.path, expr.loc, 'helper');\n var params = expr.params,\n hash = expr.hash;\n\n this.prepareHash(hash);\n this.prepareParams(params);\n };\n\n TemplateCompiler.prototype.prepareParams = function (params) {\n var i, param;\n\n if (!params.length) {\n this.opcode('literal', null, null);\n return;\n }\n for (i = params.length - 1; i >= 0; i--) {\n param = params[i];\n\n (0, _util.assert)(this[param.type], \"Unimplemented \" + param.type + \" on TemplateCompiler\");\n this[param.type](param);\n }\n this.opcode('prepareArray', null, params.length);\n };\n\n TemplateCompiler.prototype.prepareHash = function (hash) {\n var pairs = hash.pairs,\n i,\n _pairs$i,\n key,\n value;\n if (!pairs.length) {\n this.opcode('literal', null, null);\n return;\n }\n for (i = pairs.length - 1; i >= 0; i--) {\n _pairs$i = pairs[i], key = _pairs$i.key, value = _pairs$i.value;\n\n\n (0, _util.assert)(this[value.type], \"Unimplemented \" + value.type + \" on TemplateCompiler\");\n this[value.type](value);\n this.opcode('literal', null, key);\n }\n this.opcode('prepareObject', null, pairs.length);\n };\n\n TemplateCompiler.prototype.prepareAttributeValue = function (value) {\n // returns the static value if the value is static\n switch (value.type) {\n case 'TextNode':\n this.opcode('literal', value, value.chars);\n return true;\n case 'MustacheStatement':\n this.attributeMustache([value]);\n return false;\n case 'ConcatStatement':\n this.prepareConcatParts(value.parts);\n this.opcode('concat', value);\n return false;\n }\n };\n\n TemplateCompiler.prototype.prepareConcatParts = function (parts) {\n var i, part;\n\n for (i = parts.length - 1; i >= 0; i--) {\n part = parts[i];\n\n if (part.type === 'MustacheStatement') {\n this.attributeMustache([part]);\n } else if (part.type === 'TextNode') {\n this.opcode('literal', null, part.chars);\n }\n }\n this.opcode('prepareArray', null, parts.length);\n };\n\n TemplateCompiler.prototype.attributeMustache = function (_ref11) {\n var action = _ref11[0];\n\n this.mustacheExpression(action);\n };\n\n TemplateCompiler.prototype.meta = function (node) {\n var loc = node.loc;\n if (!loc) {\n return [];\n }\n var source = loc.source,\n start = loc.start,\n end = loc.end;\n\n return ['loc', [source || null, [start.line, start.column], [end.line, end.column]]];\n };\n\n _createClass(TemplateCompiler, [{\n key: \"symbols\",\n get: function () {\n return this.symbolStack.current;\n }\n }]);\n\n return TemplateCompiler;\n }();\n\n function isHelperInvocation(mustache) {\n return mustache.params && mustache.params.length > 0 || mustache.hash && mustache.hash.pairs.length > 0;\n }\n function isSimplePath(_ref12) {\n var parts = _ref12.parts;\n\n return parts.length === 1;\n }\n function isLocal(_ref13, symbols) {\n var parts = _ref13.parts;\n\n return symbols && symbols.has(parts[0]);\n }\n function isYield(path) {\n return path.original === 'yield';\n }\n function isPartial(path) {\n return path.original === 'partial';\n }\n function isDebugger(path) {\n return path.original === 'debugger';\n }\n function isHasBlock(path) {\n return path.original === 'has-block';\n }\n function isHasBlockParams(path) {\n return path.original === 'has-block-params';\n }\n function isBuiltInHelper(path) {\n return isHasBlock(path) || isHasBlockParams(path);\n }\n function isArg(path) {\n return !!path['data'];\n }\n function assertIsSimplePath(path, loc, context) {\n if (!isSimplePath(path)) {\n throw new _syntax.SyntaxError(\"`\" + path.original + \"` is not a valid name for a \" + context + \" on line \" + loc.start.line + \".\", path.loc);\n }\n }\n function assertValidYield(statement) {\n var pairs = statement.hash.pairs;\n\n if (pairs.length === 1 && pairs[0].key !== 'to' || pairs.length > 1) {\n throw new _syntax.SyntaxError(\"yield only takes a single named argument: 'to'\", statement.loc);\n } else if (pairs.length === 1 && pairs[0].value.type !== 'StringLiteral') {\n throw new _syntax.SyntaxError(\"you can only yield to a literal value\", statement.loc);\n } else if (pairs.length === 0) {\n return 'default';\n } else {\n return pairs[0].value.value;\n }\n }\n function assertValidPartial(statement) {\n var params = statement.params,\n hash = statement.hash,\n escaped = statement.escaped,\n loc = statement.loc;\n\n if (params && params.length !== 1) {\n throw new _syntax.SyntaxError(\"Partial found with no arguments. You must specify a template name. (on line \" + loc.start.line + \")\", statement.loc);\n } else if (hash && hash.pairs.length > 0) {\n throw new _syntax.SyntaxError(\"partial does not take any named arguments (on line \" + loc.start.line + \")\", statement.loc);\n } else if (!escaped) {\n throw new _syntax.SyntaxError(\"{{{partial ...}}} is not supported, please use {{partial ...}} instead (on line \" + loc.start.line + \")\", statement.loc);\n }\n return params;\n }\n function assertValidHasBlockUsage(type, call) {\n var params = call.params,\n hash = call.hash,\n loc = call.loc,\n param;\n\n if (hash && hash.pairs.length > 0) {\n throw new _syntax.SyntaxError(type + \" does not take any named arguments\", call.loc);\n }\n if (params.length === 0) {\n return 'default';\n } else if (params.length === 1) {\n param = params[0];\n\n if (param.type === 'StringLiteral') {\n return param.value;\n } else {\n throw new _syntax.SyntaxError(\"you can only yield to a literal value (on line \" + loc.start.line + \")\", call.loc);\n }\n } else {\n throw new _syntax.SyntaxError(type + \" only takes a single positional argument (on line \" + loc.start.line + \")\", call.loc);\n }\n }\n function assertValidDebuggerUsage(statement) {\n var params = statement.params,\n hash = statement.hash;\n\n if (hash && hash.pairs.length > 0) {\n throw new _syntax.SyntaxError(\"debugger does not take any named arguments\", statement.loc);\n }\n if (params.length === 0) {\n return 'default';\n } else {\n throw new _syntax.SyntaxError(\"debugger does not take any positional arguments\", statement.loc);\n }\n }\n\n var defaultId = function () {\n var crypto, idFn;\n\n if (typeof _nodeModule.require === 'function') {\n try {\n /* tslint:disable:no-require-imports */\n crypto = (0, _nodeModule.require)('crypto');\n /* tslint:enable:no-require-imports */\n\n idFn = function (src) {\n var hash = crypto.createHash('sha1');\n hash.update(src, 'utf8');\n // trim to 6 bytes of data (2^48 - 1)\n return hash.digest('base64').substring(0, 8);\n };\n\n idFn(\"test\");\n return idFn;\n } catch (e) {}\n }\n return function () {\n return null;\n };\n }();\n var defaultOptions = {\n id: defaultId,\n meta: {}\n };\n\n\n exports.precompile = function (string) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : defaultOptions;\n\n var ast = (0, _syntax.preprocess)(string, options);\n\n var _TemplateCompiler$com = TemplateCompiler.compile(options, ast),\n block = _TemplateCompiler$com.block,\n meta = _TemplateCompiler$com.meta;\n\n var idFn = options.id || defaultId;\n var blockJSON = JSON.stringify(block.toJSON());\n var templateJSONObject = {\n id: idFn(JSON.stringify(meta) + blockJSON),\n block: blockJSON,\n meta: meta\n };\n // JSON is javascript\n return JSON.stringify(templateJSONObject);\n };\n exports.TemplateVisitor = TemplateVisitor;\n});","enifed(\"@glimmer/reference\", [\"exports\", \"@glimmer/util\"], function (exports, _util) {\n \"use strict\";\n\n exports.isModified = exports.ReferenceCache = exports.map = exports.CachedReference = exports.UpdatableTag = exports.CachedTag = exports.combine = exports.combineSlice = exports.combineTagged = exports.DirtyableTag = exports.CURRENT_TAG = exports.VOLATILE_TAG = exports.CONSTANT_TAG = exports.TagWrapper = exports.RevisionTag = exports.VOLATILE = exports.INITIAL = exports.CONSTANT = exports.IteratorSynchronizer = exports.ReferenceIterator = exports.IterationArtifacts = exports.referenceFromParts = exports.ListItem = exports.isConst = exports.ConstReference = undefined;\n\n function _defaults(obj, defaults) {\n var keys = Object.getOwnPropertyNames(defaults),\n i,\n key,\n value;for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = Object.getOwnPropertyDescriptor(defaults, key);\n if (value && value.configurable && obj[key] === undefined) {\n Object.defineProperty(obj, key, value);\n }\n }return obj;\n }\n\n function _possibleConstructorReturn(self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n }\n\n function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } });if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : _defaults(subClass, superClass);\n }\n\n function _classCallCheck$1(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var CONSTANT = 0;\n var INITIAL = 1;\n var VOLATILE = NaN;\n var RevisionTag = function () {\n function RevisionTag() {\n _classCallCheck$1(this, RevisionTag);\n }\n\n RevisionTag.prototype.validate = function (snapshot) {\n return this.value() === snapshot;\n };\n\n return RevisionTag;\n }();\n RevisionTag.id = 0;\n var VALUE = [];\n var VALIDATE = [];\n var TagWrapper = function () {\n function TagWrapper(type, inner) {\n _classCallCheck$1(this, TagWrapper);\n\n this.type = type;\n this.inner = inner;\n }\n\n TagWrapper.prototype.value = function () {\n var func = VALUE[this.type];\n return func(this.inner);\n };\n\n TagWrapper.prototype.validate = function (snapshot) {\n var func = VALIDATE[this.type];\n return func(this.inner, snapshot);\n };\n\n return TagWrapper;\n }();\n function register(Type) {\n var type = VALUE.length;\n VALUE.push(function (tag) {\n return tag.value();\n });\n VALIDATE.push(function (tag, snapshot) {\n return tag.validate(snapshot);\n });\n Type.id = type;\n }\n ///\n // CONSTANT: 0\n VALUE.push(function () {\n return CONSTANT;\n });\n VALIDATE.push(function (_tag, snapshot) {\n return snapshot === CONSTANT;\n });\n var CONSTANT_TAG = new TagWrapper(0, null);\n // VOLATILE: 1\n VALUE.push(function () {\n return VOLATILE;\n });\n VALIDATE.push(function (_tag, snapshot) {\n return snapshot === VOLATILE;\n });\n var VOLATILE_TAG = new TagWrapper(1, null);\n // CURRENT: 2\n VALUE.push(function () {\n return $REVISION;\n });\n VALIDATE.push(function (_tag, snapshot) {\n return snapshot === $REVISION;\n });\n var CURRENT_TAG = new TagWrapper(2, null);\n ///\n var $REVISION = INITIAL;\n var DirtyableTag = function (_RevisionTag) {\n _inherits(DirtyableTag, _RevisionTag);\n\n DirtyableTag.create = function () {\n var revision = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : $REVISION;\n\n return new TagWrapper(this.id, new DirtyableTag(revision));\n };\n\n function DirtyableTag() {\n var revision = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : $REVISION;\n\n _classCallCheck$1(this, DirtyableTag);\n\n var _this = _possibleConstructorReturn(this, _RevisionTag.call(this));\n\n _this.revision = revision;\n return _this;\n }\n\n DirtyableTag.prototype.value = function () {\n return this.revision;\n };\n\n DirtyableTag.prototype.dirty = function () {\n this.revision = ++$REVISION;\n };\n\n return DirtyableTag;\n }(RevisionTag);\n register(DirtyableTag);\n\n function _combine(tags) {\n switch (tags.length) {\n case 0:\n return CONSTANT_TAG;\n case 1:\n return tags[0];\n case 2:\n return TagsPair.create(tags[0], tags[1]);\n default:\n return TagsCombinator.create(tags);\n }\n }\n var CachedTag = function (_RevisionTag2) {\n _inherits(CachedTag, _RevisionTag2);\n\n function CachedTag() {\n _classCallCheck$1(this, CachedTag);\n\n var _this2 = _possibleConstructorReturn(this, _RevisionTag2.apply(this, arguments));\n\n _this2.lastChecked = null;\n _this2.lastValue = null;\n return _this2;\n }\n\n CachedTag.prototype.value = function () {\n var lastChecked = this.lastChecked,\n lastValue = this.lastValue;\n\n if (lastChecked !== $REVISION) {\n this.lastChecked = $REVISION;\n this.lastValue = lastValue = this.compute();\n }\n return this.lastValue;\n };\n\n CachedTag.prototype.invalidate = function () {\n this.lastChecked = null;\n };\n\n return CachedTag;\n }(RevisionTag);\n\n var TagsPair = function (_CachedTag) {\n _inherits(TagsPair, _CachedTag);\n\n TagsPair.create = function (first, second) {\n return new TagWrapper(this.id, new TagsPair(first, second));\n };\n\n function TagsPair(first, second) {\n _classCallCheck$1(this, TagsPair);\n\n var _this3 = _possibleConstructorReturn(this, _CachedTag.call(this));\n\n _this3.first = first;\n _this3.second = second;\n return _this3;\n }\n\n TagsPair.prototype.compute = function () {\n return Math.max(this.first.value(), this.second.value());\n };\n\n return TagsPair;\n }(CachedTag);\n\n register(TagsPair);\n\n var TagsCombinator = function (_CachedTag2) {\n _inherits(TagsCombinator, _CachedTag2);\n\n TagsCombinator.create = function (tags) {\n return new TagWrapper(this.id, new TagsCombinator(tags));\n };\n\n function TagsCombinator(tags) {\n _classCallCheck$1(this, TagsCombinator);\n\n var _this4 = _possibleConstructorReturn(this, _CachedTag2.call(this));\n\n _this4.tags = tags;\n return _this4;\n }\n\n TagsCombinator.prototype.compute = function () {\n var tags = this.tags,\n i,\n value;\n\n var max = -1;\n for (i = 0; i < tags.length; i++) {\n value = tags[i].value();\n\n max = Math.max(value, max);\n }\n return max;\n };\n\n return TagsCombinator;\n }(CachedTag);\n\n register(TagsCombinator);\n var UpdatableTag = function (_CachedTag3) {\n _inherits(UpdatableTag, _CachedTag3);\n\n UpdatableTag.create = function (tag) {\n return new TagWrapper(this.id, new UpdatableTag(tag));\n };\n\n function UpdatableTag(tag) {\n _classCallCheck$1(this, UpdatableTag);\n\n var _this5 = _possibleConstructorReturn(this, _CachedTag3.call(this));\n\n _this5.tag = tag;\n _this5.lastUpdated = INITIAL;\n return _this5;\n }\n\n UpdatableTag.prototype.compute = function () {\n return Math.max(this.lastUpdated, this.tag.value());\n };\n\n UpdatableTag.prototype.update = function (tag) {\n if (tag !== this.tag) {\n this.tag = tag;\n this.lastUpdated = $REVISION;\n this.invalidate();\n }\n };\n\n return UpdatableTag;\n }(CachedTag);\n register(UpdatableTag);\n var CachedReference = function () {\n function CachedReference() {\n _classCallCheck$1(this, CachedReference);\n\n this.lastRevision = null;\n this.lastValue = null;\n }\n\n CachedReference.prototype.value = function () {\n var tag = this.tag,\n lastRevision = this.lastRevision,\n lastValue = this.lastValue;\n\n if (!lastRevision || !tag.validate(lastRevision)) {\n lastValue = this.lastValue = this.compute();\n this.lastRevision = tag.value();\n }\n return lastValue;\n };\n\n CachedReference.prototype.invalidate = function () {\n this.lastRevision = null;\n };\n\n return CachedReference;\n }();\n\n var MapperReference = function (_CachedReference) {\n _inherits(MapperReference, _CachedReference);\n\n function MapperReference(reference, mapper) {\n _classCallCheck$1(this, MapperReference);\n\n var _this6 = _possibleConstructorReturn(this, _CachedReference.call(this));\n\n _this6.tag = reference.tag;\n _this6.reference = reference;\n _this6.mapper = mapper;\n return _this6;\n }\n\n MapperReference.prototype.compute = function () {\n var reference = this.reference,\n mapper = this.mapper;\n\n return mapper(reference.value());\n };\n\n return MapperReference;\n }(CachedReference);\n\n //////////\n var ReferenceCache = function () {\n function ReferenceCache(reference) {\n _classCallCheck$1(this, ReferenceCache);\n\n this.lastValue = null;\n this.lastRevision = null;\n this.initialized = false;\n this.tag = reference.tag;\n this.reference = reference;\n }\n\n ReferenceCache.prototype.peek = function () {\n if (!this.initialized) {\n return this.initialize();\n }\n return this.lastValue;\n };\n\n ReferenceCache.prototype.revalidate = function () {\n if (!this.initialized) {\n return this.initialize();\n }\n var reference = this.reference,\n lastRevision = this.lastRevision;\n\n var tag = reference.tag;\n if (tag.validate(lastRevision)) return NOT_MODIFIED;\n this.lastRevision = tag.value();\n var lastValue = this.lastValue;\n\n var value = reference.value();\n if (value === lastValue) return NOT_MODIFIED;\n this.lastValue = value;\n return value;\n };\n\n ReferenceCache.prototype.initialize = function () {\n var reference = this.reference;\n\n var value = this.lastValue = reference.value();\n this.lastRevision = reference.tag.value();\n this.initialized = true;\n return value;\n };\n\n return ReferenceCache;\n }();\n var NOT_MODIFIED = \"adb3b78e-3d22-4e4b-877a-6317c2c5c145\";\n\n\n function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var ConstReference = function () {\n function ConstReference(inner) {\n _classCallCheck(this, ConstReference);\n\n this.inner = inner;\n this.tag = CONSTANT_TAG;\n }\n\n ConstReference.prototype.value = function () {\n return this.inner;\n };\n\n return ConstReference;\n }();\n\n\n function _defaults$1(obj, defaults) {\n var keys = Object.getOwnPropertyNames(defaults),\n i,\n key,\n value;for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = Object.getOwnPropertyDescriptor(defaults, key);\n if (value && value.configurable && obj[key] === undefined) {\n Object.defineProperty(obj, key, value);\n }\n }return obj;\n }\n\n function _classCallCheck$2(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n function _possibleConstructorReturn$1(self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n }\n\n function _inherits$1(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } });if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : _defaults$1(subClass, superClass);\n }\n\n var ListItem = function (_ListNode) {\n _inherits$1(ListItem, _ListNode);\n\n function ListItem(iterable, result) {\n _classCallCheck$2(this, ListItem);\n\n var _this = _possibleConstructorReturn$1(this, _ListNode.call(this, iterable.valueReferenceFor(result)));\n\n _this.retained = false;\n _this.seen = false;\n _this.key = result.key;\n _this.iterable = iterable;\n _this.memo = iterable.memoReferenceFor(result);\n return _this;\n }\n\n ListItem.prototype.update = function (item) {\n this.retained = true;\n this.iterable.updateValueReference(this.value, item);\n this.iterable.updateMemoReference(this.memo, item);\n };\n\n ListItem.prototype.shouldRemove = function () {\n return !this.retained;\n };\n\n ListItem.prototype.reset = function () {\n this.retained = false;\n this.seen = false;\n };\n\n return ListItem;\n }(_util.ListNode);\n var IterationArtifacts = function () {\n function IterationArtifacts(iterable) {\n _classCallCheck$2(this, IterationArtifacts);\n\n this.map = (0, _util.dict)();\n this.list = new _util.LinkedList();\n this.tag = iterable.tag;\n this.iterable = iterable;\n }\n\n IterationArtifacts.prototype.isEmpty = function () {\n var iterator = this.iterator = this.iterable.iterate();\n return iterator.isEmpty();\n };\n\n IterationArtifacts.prototype.iterate = function () {\n var iterator = this.iterator || this.iterable.iterate();\n this.iterator = null;\n return iterator;\n };\n\n IterationArtifacts.prototype.has = function (key) {\n return !!this.map[key];\n };\n\n IterationArtifacts.prototype.get = function (key) {\n return this.map[key];\n };\n\n IterationArtifacts.prototype.wasSeen = function (key) {\n var node = this.map[key];\n return node && node.seen;\n };\n\n IterationArtifacts.prototype.append = function (item) {\n var map = this.map,\n list = this.list,\n iterable = this.iterable;\n\n var node = map[item.key] = new ListItem(iterable, item);\n list.append(node);\n return node;\n };\n\n IterationArtifacts.prototype.insertBefore = function (item, reference) {\n var map = this.map,\n list = this.list,\n iterable = this.iterable;\n\n var node = map[item.key] = new ListItem(iterable, item);\n node.retained = true;\n list.insertBefore(node, reference);\n return node;\n };\n\n IterationArtifacts.prototype.move = function (item, reference) {\n var list = this.list;\n\n item.retained = true;\n list.remove(item);\n list.insertBefore(item, reference);\n };\n\n IterationArtifacts.prototype.remove = function (item) {\n var list = this.list;\n\n list.remove(item);\n delete this.map[item.key];\n };\n\n IterationArtifacts.prototype.nextNode = function (item) {\n return this.list.nextNode(item);\n };\n\n IterationArtifacts.prototype.head = function () {\n return this.list.head();\n };\n\n return IterationArtifacts;\n }();\n var ReferenceIterator = function () {\n // if anyone needs to construct this object with something other than\n // an iterable, let @wycats know.\n function ReferenceIterator(iterable) {\n _classCallCheck$2(this, ReferenceIterator);\n\n this.iterator = null;\n var artifacts = new IterationArtifacts(iterable);\n this.artifacts = artifacts;\n }\n\n ReferenceIterator.prototype.next = function () {\n var artifacts = this.artifacts;\n\n var iterator = this.iterator = this.iterator || artifacts.iterate();\n var item = iterator.next();\n if (!item) return null;\n return artifacts.append(item);\n };\n\n return ReferenceIterator;\n }();\n var Phase;\n (function (Phase) {\n Phase[Phase[\"Append\"] = 0] = \"Append\";\n Phase[Phase[\"Prune\"] = 1] = \"Prune\";\n Phase[Phase[\"Done\"] = 2] = \"Done\";\n })(Phase || (Phase = {}));\n var IteratorSynchronizer = function () {\n function IteratorSynchronizer(_ref) {\n var target = _ref.target,\n artifacts = _ref.artifacts;\n\n _classCallCheck$2(this, IteratorSynchronizer);\n\n this.target = target;\n this.artifacts = artifacts;\n this.iterator = artifacts.iterate();\n this.current = artifacts.head();\n }\n\n IteratorSynchronizer.prototype.sync = function () {\n var phase = Phase.Append;\n while (true) {\n switch (phase) {\n case Phase.Append:\n phase = this.nextAppend();\n break;\n case Phase.Prune:\n phase = this.nextPrune();\n break;\n case Phase.Done:\n this.nextDone();\n return;\n }\n }\n };\n\n IteratorSynchronizer.prototype.advanceToKey = function (key) {\n var current = this.current,\n artifacts = this.artifacts;\n\n var seek = current;\n while (seek && seek.key !== key) {\n seek.seen = true;\n seek = artifacts.nextNode(seek);\n }\n this.current = seek && artifacts.nextNode(seek);\n };\n\n IteratorSynchronizer.prototype.nextAppend = function () {\n var iterator = this.iterator,\n current = this.current,\n artifacts = this.artifacts;\n\n var item = iterator.next();\n if (item === null) {\n return this.startPrune();\n }\n var key = item.key;\n\n if (current && current.key === key) {\n this.nextRetain(item);\n } else if (artifacts.has(key)) {\n this.nextMove(item);\n } else {\n this.nextInsert(item);\n }\n return Phase.Append;\n };\n\n IteratorSynchronizer.prototype.nextRetain = function (item) {\n var artifacts = this.artifacts,\n current = this.current;\n\n current = current;\n current.update(item);\n this.current = artifacts.nextNode(current);\n this.target.retain(item.key, current.value, current.memo);\n };\n\n IteratorSynchronizer.prototype.nextMove = function (item) {\n var current = this.current,\n artifacts = this.artifacts,\n target = this.target;\n var key = item.key;\n\n var found = artifacts.get(item.key);\n found.update(item);\n if (artifacts.wasSeen(item.key)) {\n artifacts.move(found, current);\n target.move(found.key, found.value, found.memo, current ? current.key : null);\n } else {\n this.advanceToKey(key);\n }\n };\n\n IteratorSynchronizer.prototype.nextInsert = function (item) {\n var artifacts = this.artifacts,\n target = this.target,\n current = this.current;\n\n var node = artifacts.insertBefore(item, current);\n target.insert(node.key, node.value, node.memo, current ? current.key : null);\n };\n\n IteratorSynchronizer.prototype.startPrune = function () {\n this.current = this.artifacts.head();\n return Phase.Prune;\n };\n\n IteratorSynchronizer.prototype.nextPrune = function () {\n var artifacts = this.artifacts,\n target = this.target,\n current = this.current;\n\n if (current === null) {\n return Phase.Done;\n }\n var node = current;\n this.current = artifacts.nextNode(node);\n if (node.shouldRemove()) {\n artifacts.remove(node);\n target.delete(node.key);\n } else {\n node.reset();\n }\n return Phase.Prune;\n };\n\n IteratorSynchronizer.prototype.nextDone = function () {\n this.target.done();\n };\n\n return IteratorSynchronizer;\n }();\n\n exports.ConstReference = ConstReference;\n exports.isConst = function (reference) {\n return reference.tag === CONSTANT_TAG;\n };\n exports.ListItem = ListItem;\n exports.referenceFromParts = function (root, parts) {\n var reference = root,\n i;\n for (i = 0; i < parts.length; i++) {\n reference = reference.get(parts[i]);\n }\n return reference;\n };\n exports.IterationArtifacts = IterationArtifacts;\n exports.ReferenceIterator = ReferenceIterator;\n exports.IteratorSynchronizer = IteratorSynchronizer;\n exports.CONSTANT = CONSTANT;\n exports.INITIAL = INITIAL;\n exports.VOLATILE = VOLATILE;\n exports.RevisionTag = RevisionTag;\n exports.TagWrapper = TagWrapper;\n exports.CONSTANT_TAG = CONSTANT_TAG;\n exports.VOLATILE_TAG = VOLATILE_TAG;\n exports.CURRENT_TAG = CURRENT_TAG;\n exports.DirtyableTag = DirtyableTag;\n exports.combineTagged = function (tagged) {\n var optimized = [],\n i,\n l,\n tag;\n for (i = 0, l = tagged.length; i < l; i++) {\n tag = tagged[i].tag;\n\n if (tag === VOLATILE_TAG) return VOLATILE_TAG;\n if (tag === CONSTANT_TAG) continue;\n optimized.push(tag);\n }\n return _combine(optimized);\n };\n exports.combineSlice = function (slice) {\n var optimized = [],\n tag;\n var node = slice.head();\n while (node !== null) {\n tag = node.tag;\n\n if (tag === VOLATILE_TAG) return VOLATILE_TAG;\n if (tag !== CONSTANT_TAG) optimized.push(tag);\n node = slice.nextNode(node);\n }\n return _combine(optimized);\n };\n exports.combine = function (tags) {\n var optimized = [],\n i,\n l,\n tag;\n for (i = 0, l = tags.length; i < l; i++) {\n tag = tags[i];\n\n if (tag === VOLATILE_TAG) return VOLATILE_TAG;\n if (tag === CONSTANT_TAG) continue;\n optimized.push(tag);\n }\n return _combine(optimized);\n };\n exports.CachedTag = CachedTag;\n exports.UpdatableTag = UpdatableTag;\n exports.CachedReference = CachedReference;\n exports.map = function (reference, mapper) {\n return new MapperReference(reference, mapper);\n };\n exports.ReferenceCache = ReferenceCache;\n exports.isModified = function (value) {\n return value !== NOT_MODIFIED;\n };\n});","enifed('@glimmer/syntax', ['exports', 'simple-html-tokenizer', '@glimmer/util', 'handlebars'], function (exports, _simpleHtmlTokenizer, _util, _handlebars) {\n 'use strict';\n\n exports.printLiteral = exports.isLiteral = exports.SyntaxError = exports.print = exports.Walker = exports.traverse = exports.builders = exports.preprocess = exports.AST = undefined;\n\n function isLiteral(input) {\n return !!(typeof input === 'object' && input.type.match(/Literal$/));\n }\n\n var nodes = Object.freeze({\n isCall: function (node) {\n return node.type === 'SubExpression' || node.type === 'MustacheStatement' && node.path.type === 'PathExpression';\n },\n isLiteral: isLiteral\n });\n // Expressions\n\n function buildPath(original, loc) {\n if (typeof original !== 'string') return original;\n var parts = original.split('.');\n var thisHead = false;\n if (parts[0] === 'this') {\n thisHead = true;\n parts = parts.slice(1);\n }\n return {\n type: \"PathExpression\",\n original: original,\n this: thisHead,\n parts: parts,\n data: false,\n loc: buildLoc(loc || null)\n };\n }\n function buildLiteral(type, value, loc) {\n return {\n type: type,\n value: value,\n original: value,\n loc: buildLoc(loc || null)\n };\n }\n // Miscellaneous\n function buildHash(pairs, loc) {\n return {\n type: \"Hash\",\n pairs: pairs || [],\n loc: buildLoc(loc || null)\n };\n }\n\n function buildSource(source) {\n return source || null;\n }\n function buildPosition(line, column) {\n return {\n line: line,\n column: column\n };\n }\n var SYNTHETIC = { source: '(synthetic)', start: { line: 1, column: 0 }, end: { line: 1, column: 0 } };\n function buildLoc() {\n var _len, args, _key, loc, startLine, startColumn, endLine, endColumn, source;\n\n for (_len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n if (args.length === 1) {\n loc = args[0];\n\n if (loc && typeof loc === 'object') {\n return {\n source: buildSource(loc.source),\n start: buildPosition(loc.start.line, loc.start.column),\n end: buildPosition(loc.end.line, loc.end.column)\n };\n } else {\n return SYNTHETIC;\n }\n } else {\n startLine = args[0], startColumn = args[1], endLine = args[2], endColumn = args[3], source = args[4];\n\n\n return {\n source: buildSource(source),\n start: buildPosition(startLine, startColumn),\n end: buildPosition(endLine, endColumn)\n };\n }\n }\n var b = {\n mustache: function (path, params, hash, raw, loc) {\n if (!isLiteral(path)) {\n path = buildPath(path);\n }\n return {\n type: \"MustacheStatement\",\n path: path,\n params: params || [],\n hash: hash || buildHash([]),\n escaped: !raw,\n loc: buildLoc(loc || null)\n };\n },\n block: function (path, params, hash, program, inverse, loc) {\n return {\n type: \"BlockStatement\",\n path: buildPath(path),\n params: params || [],\n hash: hash || buildHash([]),\n program: program || null,\n inverse: inverse || null,\n loc: buildLoc(loc || null)\n };\n },\n partial: function (name, params, hash, indent, loc) {\n return {\n type: \"PartialStatement\",\n name: name,\n params: params || [],\n hash: hash || buildHash([]),\n indent: indent || '',\n strip: { open: false, close: false },\n loc: buildLoc(loc || null)\n };\n },\n comment: function (value, loc) {\n return {\n type: \"CommentStatement\",\n value: value,\n loc: buildLoc(loc || null)\n };\n },\n mustacheComment: function (value, loc) {\n return {\n type: \"MustacheCommentStatement\",\n value: value,\n loc: buildLoc(loc || null)\n };\n },\n element: function (tag, attributes, modifiers, children, comments, loc) {\n // this is used for backwards compat prior to `comments` being added to the AST\n if (!Array.isArray(comments)) {\n loc = comments;\n comments = [];\n }\n return {\n type: \"ElementNode\",\n tag: tag || \"\",\n attributes: attributes || [],\n blockParams: [],\n modifiers: modifiers || [],\n comments: comments || [],\n children: children || [],\n loc: buildLoc(loc || null)\n };\n },\n elementModifier: function (path, params, hash, loc) {\n return {\n type: \"ElementModifierStatement\",\n path: buildPath(path),\n params: params || [],\n hash: hash || buildHash([]),\n loc: buildLoc(loc || null)\n };\n },\n attr: function (name, value, loc) {\n return {\n type: \"AttrNode\",\n name: name,\n value: value,\n loc: buildLoc(loc || null)\n };\n },\n text: function (chars, loc) {\n return {\n type: \"TextNode\",\n chars: chars || \"\",\n loc: buildLoc(loc || null)\n };\n },\n sexpr: function (path, params, hash, loc) {\n return {\n type: \"SubExpression\",\n path: buildPath(path),\n params: params || [],\n hash: hash || buildHash([]),\n loc: buildLoc(loc || null)\n };\n },\n path: buildPath,\n concat: function (parts, loc) {\n return {\n type: \"ConcatStatement\",\n parts: parts || [],\n loc: buildLoc(loc || null)\n };\n },\n hash: buildHash,\n pair: function (key, value, loc) {\n return {\n type: \"HashPair\",\n key: key,\n value: value,\n loc: buildLoc(loc || null)\n };\n },\n literal: buildLiteral,\n program: function (body, blockParams, loc) {\n return {\n type: \"Program\",\n body: body || [],\n blockParams: blockParams || [],\n loc: buildLoc(loc || null)\n };\n },\n loc: buildLoc,\n pos: buildPosition,\n string: literal('StringLiteral'),\n boolean: literal('BooleanLiteral'),\n number: literal('NumberLiteral'),\n undefined: function () {\n return buildLiteral('UndefinedLiteral', undefined);\n },\n null: function () {\n return buildLiteral('NullLiteral', null);\n }\n };\n function literal(type) {\n return function (value) {\n return buildLiteral(type, value);\n };\n }\n\n /**\n * Subclass of `Error` with additional information\n * about location of incorrect markup.\n */\n var SyntaxError = function () {\n SyntaxError.prototype = Object.create(Error.prototype);\n SyntaxError.prototype.constructor = SyntaxError;\n function SyntaxError(message, location) {\n var error = Error.call(this, message);\n this.message = message;\n this.stack = error.stack;\n this.location = location;\n }\n return SyntaxError;\n }();\n\n // Regex to validate the identifier for block parameters.\n // Based on the ID validation regex in Handlebars.\n var ID_INVERSE_PATTERN = /[!\"#%-,\\.\\/;->@\\[-\\^`\\{-~]/;\n // Checks the element's attributes to see if it uses block params.\n // If it does, registers the block params with the program and\n // removes the corresponding attributes from the element.\n function parseElementBlockParams(element) {\n var params = parseBlockParams(element);\n if (params) element.blockParams = params;\n }\n function parseBlockParams(element) {\n var l = element.attributes.length,\n i,\n paramsString,\n params,\n _i,\n param;\n var attrNames = [];\n for (i = 0; i < l; i++) {\n attrNames.push(element.attributes[i].name);\n }\n var asIndex = attrNames.indexOf('as');\n if (asIndex !== -1 && l > asIndex && attrNames[asIndex + 1].charAt(0) === '|') {\n // Some basic validation, since we're doing the parsing ourselves\n paramsString = attrNames.slice(asIndex).join(' ');\n\n if (paramsString.charAt(paramsString.length - 1) !== '|' || paramsString.match(/\\|/g).length !== 2) {\n throw new SyntaxError('Invalid block parameters syntax: \\'' + paramsString + '\\'', element.loc);\n }\n params = [];\n\n for (_i = asIndex + 1; _i < l; _i++) {\n param = attrNames[_i].replace(/\\|/g, '');\n\n if (param !== '') {\n if (ID_INVERSE_PATTERN.test(param)) {\n throw new SyntaxError('Invalid identifier for block parameters: \\'' + param + '\\' in \\'' + paramsString + '\\'', element.loc);\n }\n params.push(param);\n }\n }\n if (params.length === 0) {\n throw new SyntaxError('Cannot use zero block parameters: \\'' + paramsString + '\\'', element.loc);\n }\n element.attributes = element.attributes.slice(0, asIndex);\n return params;\n }\n return null;\n }\n function childrenFor(node) {\n switch (node.type) {\n case 'Program':\n return node.body;\n case 'ElementNode':\n return node.children;\n }\n }\n function appendChild(parent, node) {\n childrenFor(parent).push(node);\n }\n function isLiteral$1(path) {\n return path.type === 'StringLiteral' || path.type === 'BooleanLiteral' || path.type === 'NumberLiteral' || path.type === 'NullLiteral' || path.type === 'UndefinedLiteral';\n }\n function printLiteral(literal) {\n if (literal.type === 'UndefinedLiteral') {\n return 'undefined';\n } else {\n return JSON.stringify(literal.value);\n }\n }\n\n var _createClass = function () {\n function defineProperties(target, props) {\n var i, descriptor;\n\n for (i = 0; i < props.length; i++) {\n descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;descriptor.configurable = true;if (\"value\" in descriptor) descriptor.writable = true;Object.defineProperty(target, descriptor.key, descriptor);\n }\n }return function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);if (staticProps) defineProperties(Constructor, staticProps);return Constructor;\n };\n }();\n\n function _classCallCheck$2(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var entityParser = new _simpleHtmlTokenizer.EntityParser(_simpleHtmlTokenizer.HTML5NamedCharRefs);\n var Parser = function () {\n function Parser(source) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n _classCallCheck$2(this, Parser);\n\n this.elementStack = [];\n this.currentAttribute = null;\n this.currentNode = null;\n this.tokenizer = new _simpleHtmlTokenizer.EventedTokenizer(this, entityParser);\n this.options = options;\n this.source = source.split(/(?:\\r\\n?|\\n)/g);\n }\n\n Parser.prototype.acceptNode = function (node) {\n return this[node.type](node);\n };\n\n Parser.prototype.currentElement = function () {\n return this.elementStack[this.elementStack.length - 1];\n };\n\n Parser.prototype.sourceForNode = function (node, endNode) {\n var firstLine = node.loc.start.line - 1;\n var currentLine = firstLine - 1;\n var firstColumn = node.loc.start.column;\n var string = [];\n var line = void 0;\n var lastLine = void 0;\n var lastColumn = void 0;\n if (endNode) {\n lastLine = endNode.loc.end.line - 1;\n lastColumn = endNode.loc.end.column;\n } else {\n lastLine = node.loc.end.line - 1;\n lastColumn = node.loc.end.column;\n }\n while (currentLine < lastLine) {\n currentLine++;\n line = this.source[currentLine];\n if (currentLine === firstLine) {\n if (firstLine === lastLine) {\n string.push(line.slice(firstColumn, lastColumn));\n } else {\n string.push(line.slice(firstColumn));\n }\n } else if (currentLine === lastLine) {\n string.push(line.slice(0, lastColumn));\n } else {\n string.push(line);\n }\n }\n return string.join('\\n');\n };\n\n _createClass(Parser, [{\n key: 'currentAttr',\n get: function () {\n return this.currentAttribute;\n }\n }, {\n key: 'currentTag',\n get: function () {\n var node = this.currentNode;\n (0, _util.assert)(node && (node.type === 'StartTag' || node.type === 'EndTag'), 'expected tag');\n return node;\n }\n }, {\n key: 'currentStartTag',\n get: function () {\n var node = this.currentNode;\n (0, _util.assert)(node && node.type === 'StartTag', 'expected start tag');\n return node;\n }\n }, {\n key: 'currentEndTag',\n get: function () {\n var node = this.currentNode;\n (0, _util.assert)(node && node.type === 'EndTag', 'expected end tag');\n return node;\n }\n }, {\n key: 'currentComment',\n get: function () {\n var node = this.currentNode;\n (0, _util.assert)(node && node.type === 'CommentStatement', 'expected a comment');\n return node;\n }\n }, {\n key: 'currentData',\n get: function () {\n var node = this.currentNode;\n (0, _util.assert)(node && node.type === 'TextNode', 'expected a text node');\n return node;\n }\n }]);\n\n return Parser;\n }();\n\n function _defaults$1(obj, defaults) {\n var keys = Object.getOwnPropertyNames(defaults),\n i,\n key,\n value;for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = Object.getOwnPropertyDescriptor(defaults, key);\n if (value && value.configurable && obj[key] === undefined) {\n Object.defineProperty(obj, key, value);\n }\n }return obj;\n }\n\n function _classCallCheck$1(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n function _possibleConstructorReturn$1(self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n }\n\n function _inherits$1(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } });if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : _defaults$1(subClass, superClass);\n }\n\n var HandlebarsNodeVisitors = function (_Parser) {\n _inherits$1(HandlebarsNodeVisitors, _Parser);\n\n function HandlebarsNodeVisitors() {\n _classCallCheck$1(this, HandlebarsNodeVisitors);\n\n return _possibleConstructorReturn$1(this, _Parser.apply(this, arguments));\n }\n\n HandlebarsNodeVisitors.prototype.Program = function (program) {\n var node = b.program([], program.blockParams, program.loc),\n elementNode;\n var i = void 0,\n l = program.body.length;\n this.elementStack.push(node);\n if (l === 0) {\n return this.elementStack.pop();\n }\n for (i = 0; i < l; i++) {\n this.acceptNode(program.body[i]);\n }\n // Ensure that that the element stack is balanced properly.\n var poppedNode = this.elementStack.pop();\n if (poppedNode !== node) {\n elementNode = poppedNode;\n\n throw new SyntaxError(\"Unclosed element `\" + elementNode.tag + \"` (on line \" + elementNode.loc.start.line + \").\", elementNode.loc);\n }\n return node;\n };\n\n HandlebarsNodeVisitors.prototype.BlockStatement = function (block) {\n if (this.tokenizer['state'] === 'comment') {\n this.appendToCommentData(this.sourceForNode(block));\n return;\n }\n if (this.tokenizer['state'] !== 'comment' && this.tokenizer['state'] !== 'data' && this.tokenizer['state'] !== 'beforeData') {\n throw new SyntaxError(\"A block may only be used inside an HTML element or another block.\", block.loc);\n }\n\n var _acceptCallNodes = acceptCallNodes(this, block),\n path = _acceptCallNodes.path,\n params = _acceptCallNodes.params,\n hash = _acceptCallNodes.hash;\n\n var program = this.Program(block.program);\n var inverse = block.inverse ? this.Program(block.inverse) : null;\n var node = b.block(path, params, hash, program, inverse, block.loc);\n var parentProgram = this.currentElement();\n appendChild(parentProgram, node);\n };\n\n HandlebarsNodeVisitors.prototype.MustacheStatement = function (rawMustache) {\n var tokenizer = this.tokenizer,\n _acceptCallNodes2,\n path,\n params,\n hash;\n\n if (tokenizer['state'] === 'comment') {\n this.appendToCommentData(this.sourceForNode(rawMustache));\n return;\n }\n var mustache = void 0;\n var escaped = rawMustache.escaped,\n loc = rawMustache.loc;\n\n if (rawMustache.path.type.match(/Literal$/)) {\n mustache = {\n type: 'MustacheStatement',\n path: this.acceptNode(rawMustache.path),\n params: [],\n hash: b.hash(),\n escaped: escaped,\n loc: loc\n };\n } else {\n _acceptCallNodes2 = acceptCallNodes(this, rawMustache), path = _acceptCallNodes2.path, params = _acceptCallNodes2.params, hash = _acceptCallNodes2.hash;\n\n\n mustache = b.mustache(path, params, hash, !escaped, loc);\n }\n switch (tokenizer.state) {\n // Tag helpers\n case \"tagName\":\n addElementModifier(this.currentStartTag, mustache);\n tokenizer.state = \"beforeAttributeName\";\n break;\n case \"beforeAttributeName\":\n addElementModifier(this.currentStartTag, mustache);\n break;\n case \"attributeName\":\n case \"afterAttributeName\":\n this.beginAttributeValue(false);\n this.finishAttributeValue();\n addElementModifier(this.currentStartTag, mustache);\n tokenizer.state = \"beforeAttributeName\";\n break;\n case \"afterAttributeValueQuoted\":\n addElementModifier(this.currentStartTag, mustache);\n tokenizer.state = \"beforeAttributeName\";\n break;\n // Attribute values\n case \"beforeAttributeValue\":\n appendDynamicAttributeValuePart(this.currentAttribute, mustache);\n tokenizer.state = 'attributeValueUnquoted';\n break;\n case \"attributeValueDoubleQuoted\":\n case \"attributeValueSingleQuoted\":\n case \"attributeValueUnquoted\":\n appendDynamicAttributeValuePart(this.currentAttribute, mustache);\n break;\n // TODO: Only append child when the tokenizer state makes\n // sense to do so, otherwise throw an error.\n default:\n appendChild(this.currentElement(), mustache);\n }\n return mustache;\n };\n\n HandlebarsNodeVisitors.prototype.ContentStatement = function (content) {\n updateTokenizerLocation(this.tokenizer, content);\n this.tokenizer.tokenizePart(content.value);\n this.tokenizer.flushData();\n };\n\n HandlebarsNodeVisitors.prototype.CommentStatement = function (rawComment) {\n var tokenizer = this.tokenizer;\n\n if (tokenizer.state === 'comment') {\n this.appendToCommentData(this.sourceForNode(rawComment));\n return null;\n }\n var value = rawComment.value,\n loc = rawComment.loc;\n\n var comment = b.mustacheComment(value, loc);\n switch (tokenizer.state) {\n case \"beforeAttributeName\":\n this.currentStartTag.comments.push(comment);\n break;\n case 'beforeData':\n case 'data':\n appendChild(this.currentElement(), comment);\n break;\n default:\n throw new SyntaxError(\"Using a Handlebars comment when in the `\" + tokenizer.state + \"` state is not supported: \\\"\" + comment.value + \"\\\" on line \" + loc.start.line + \":\" + loc.start.column, rawComment.loc);\n }\n return comment;\n };\n\n HandlebarsNodeVisitors.prototype.PartialStatement = function (partial) {\n var loc = partial.loc;\n\n throw new SyntaxError(\"Handlebars partials are not supported: \\\"\" + this.sourceForNode(partial, partial.name) + \"\\\" at L\" + loc.start.line + \":C\" + loc.start.column, partial.loc);\n };\n\n HandlebarsNodeVisitors.prototype.PartialBlockStatement = function (partialBlock) {\n var loc = partialBlock.loc;\n\n throw new SyntaxError(\"Handlebars partial blocks are not supported: \\\"\" + this.sourceForNode(partialBlock, partialBlock.name) + \"\\\" at L\" + loc.start.line + \":C\" + loc.start.column, partialBlock.loc);\n };\n\n HandlebarsNodeVisitors.prototype.Decorator = function (decorator) {\n var loc = decorator.loc;\n\n throw new SyntaxError(\"Handlebars decorators are not supported: \\\"\" + this.sourceForNode(decorator, decorator.path) + \"\\\" at L\" + loc.start.line + \":C\" + loc.start.column, decorator.loc);\n };\n\n HandlebarsNodeVisitors.prototype.DecoratorBlock = function (decoratorBlock) {\n var loc = decoratorBlock.loc;\n\n throw new SyntaxError(\"Handlebars decorator blocks are not supported: \\\"\" + this.sourceForNode(decoratorBlock, decoratorBlock.path) + \"\\\" at L\" + loc.start.line + \":C\" + loc.start.column, decoratorBlock.loc);\n };\n\n HandlebarsNodeVisitors.prototype.SubExpression = function (sexpr) {\n var _acceptCallNodes3 = acceptCallNodes(this, sexpr),\n path = _acceptCallNodes3.path,\n params = _acceptCallNodes3.params,\n hash = _acceptCallNodes3.hash;\n\n return b.sexpr(path, params, hash, sexpr.loc);\n };\n\n HandlebarsNodeVisitors.prototype.PathExpression = function (path) {\n var original = path.original,\n loc = path.loc;\n\n var parts = void 0;\n if (original.indexOf('/') !== -1) {\n if (original.slice(0, 2) === './') {\n throw new SyntaxError(\"Using \\\"./\\\" is not supported in Glimmer and unnecessary: \\\"\" + path.original + \"\\\" on line \" + loc.start.line + \".\", path.loc);\n }\n if (original.slice(0, 3) === '../') {\n throw new SyntaxError(\"Changing context using \\\"../\\\" is not supported in Glimmer: \\\"\" + path.original + \"\\\" on line \" + loc.start.line + \".\", path.loc);\n }\n if (original.indexOf('.') !== -1) {\n throw new SyntaxError(\"Mixing '.' and '/' in paths is not supported in Glimmer; use only '.' to separate property paths: \\\"\" + path.original + \"\\\" on line \" + loc.start.line + \".\", path.loc);\n }\n parts = [path.parts.join('/')];\n } else {\n parts = path.parts;\n }\n var thisHead = false;\n // This is to fix a bug in the Handlebars AST where the path expressions in\n // `{{this.foo}}` (and similarly `{{foo-bar this.foo named=this.foo}}` etc)\n // are simply turned into `{{foo}}`. The fix is to push it back onto the\n // parts array and let the runtime see the difference. However, we cannot\n // simply use the string `this` as it means literally the property called\n // \"this\" in the current context (it can be expressed in the syntax as\n // `{{[this]}}`, where the square bracket are generally for this kind of\n // escaping – such as `{{foo.[\"bar.baz\"]}}` would mean lookup a property\n // named literally \"bar.baz\" on `this.foo`). By convention, we use `null`\n // for this purpose.\n if (original.match(/^this(\\..+)?$/)) {\n thisHead = true;\n }\n return {\n type: 'PathExpression',\n original: path.original,\n this: thisHead,\n parts: parts,\n data: path.data,\n loc: path.loc\n };\n };\n\n HandlebarsNodeVisitors.prototype.Hash = function (hash) {\n var pairs = [],\n i,\n pair;\n for (i = 0; i < hash.pairs.length; i++) {\n pair = hash.pairs[i];\n\n pairs.push(b.pair(pair.key, this.acceptNode(pair.value), pair.loc));\n }\n return b.hash(pairs, hash.loc);\n };\n\n HandlebarsNodeVisitors.prototype.StringLiteral = function (string) {\n return b.literal('StringLiteral', string.value, string.loc);\n };\n\n HandlebarsNodeVisitors.prototype.BooleanLiteral = function (boolean) {\n return b.literal('BooleanLiteral', boolean.value, boolean.loc);\n };\n\n HandlebarsNodeVisitors.prototype.NumberLiteral = function (number) {\n return b.literal('NumberLiteral', number.value, number.loc);\n };\n\n HandlebarsNodeVisitors.prototype.UndefinedLiteral = function (undef) {\n return b.literal('UndefinedLiteral', undefined, undef.loc);\n };\n\n HandlebarsNodeVisitors.prototype.NullLiteral = function (nul) {\n return b.literal('NullLiteral', null, nul.loc);\n };\n\n return HandlebarsNodeVisitors;\n }(Parser);\n function calculateRightStrippedOffsets(original, value) {\n if (value === '') {\n // if it is empty, just return the count of newlines\n // in original\n return {\n lines: original.split(\"\\n\").length - 1,\n columns: 0\n };\n }\n // otherwise, return the number of newlines prior to\n // `value`\n var difference = original.split(value)[0];\n var lines = difference.split(/\\n/);\n var lineCount = lines.length - 1;\n return {\n lines: lineCount,\n columns: lines[lineCount].length\n };\n }\n function updateTokenizerLocation(tokenizer, content) {\n var line = content.loc.start.line;\n var column = content.loc.start.column;\n var offsets = calculateRightStrippedOffsets(content.original, content.value);\n line = line + offsets.lines;\n if (offsets.lines) {\n column = offsets.columns;\n } else {\n column = column + offsets.columns;\n }\n tokenizer.line = line;\n tokenizer.column = column;\n }\n function acceptCallNodes(compiler, node) {\n var path = compiler.PathExpression(node.path);\n var params = node.params ? node.params.map(function (e) {\n return compiler.acceptNode(e);\n }) : [];\n var hash = node.hash ? compiler.Hash(node.hash) : b.hash();\n return { path: path, params: params, hash: hash };\n }\n function addElementModifier(element, mustache) {\n var path = mustache.path,\n params = mustache.params,\n hash = mustache.hash,\n loc = mustache.loc,\n _modifier,\n tag;\n\n if (isLiteral$1(path)) {\n _modifier = \"{{\" + printLiteral(path) + \"}}\";\n tag = \"<\" + element.name + \" ... \" + _modifier + \" ...\";\n\n throw new SyntaxError(\"In \" + tag + \", \" + _modifier + \" is not a valid modifier: \\\"\" + path.original + \"\\\" on line \" + (loc && loc.start.line) + \".\", mustache.loc);\n }\n var modifier = b.elementModifier(path, params, hash, loc);\n element.modifiers.push(modifier);\n }\n function appendDynamicAttributeValuePart(attribute, part) {\n attribute.isDynamic = true;\n attribute.parts.push(part);\n }\n\n var visitorKeys = {\n Program: ['body'],\n MustacheStatement: ['path', 'params', 'hash'],\n BlockStatement: ['path', 'params', 'hash', 'program', 'inverse'],\n ElementModifierStatement: ['path', 'params', 'hash'],\n PartialStatement: ['name', 'params', 'hash'],\n CommentStatement: [],\n MustacheCommentStatement: [],\n ElementNode: ['attributes', 'modifiers', 'children', 'comments'],\n AttrNode: ['value'],\n TextNode: [],\n ConcatStatement: ['parts'],\n SubExpression: ['path', 'params', 'hash'],\n PathExpression: [],\n StringLiteral: [],\n BooleanLiteral: [],\n NumberLiteral: [],\n NullLiteral: [],\n UndefinedLiteral: [],\n Hash: ['pairs'],\n HashPair: ['value']\n };\n\n var TraversalError = function () {\n TraversalError.prototype = Object.create(Error.prototype);\n TraversalError.prototype.constructor = TraversalError;\n function TraversalError(message, node, parent, key) {\n var error = Error.call(this, message);\n this.key = key;\n this.message = message;\n this.node = node;\n this.parent = parent;\n this.stack = error.stack;\n }\n return TraversalError;\n }();\n function cannotRemoveNode(node, parent, key) {\n return new TraversalError(\"Cannot remove a node unless it is part of an array\", node, parent, key);\n }\n function cannotReplaceNode(node, parent, key) {\n return new TraversalError(\"Cannot replace a node with multiple nodes unless it is part of an array\", node, parent, key);\n }\n function cannotReplaceOrRemoveInKeyHandlerYet(node, key) {\n return new TraversalError(\"Replacing and removing in key handlers is not yet supported.\", node, null, key);\n }\n\n function visitNode(visitor, node) {\n var handler = visitor[node.type] || visitor.All || null,\n keys,\n i;\n var result = void 0;\n if (handler && handler['enter']) {\n result = handler['enter'].call(null, node);\n }\n if (result !== undefined && result !== null) {\n if (JSON.stringify(node) === JSON.stringify(result)) {\n result = undefined;\n } else if (Array.isArray(result)) {\n return visitArray(visitor, result) || result;\n } else {\n return visitNode(visitor, result) || result;\n }\n }\n if (result === undefined) {\n keys = visitorKeys[node.type];\n\n for (i = 0; i < keys.length; i++) {\n visitKey(visitor, handler, node, keys[i]);\n }\n if (handler && handler['exit']) {\n result = handler['exit'].call(null, node);\n }\n }\n return result;\n }\n function visitKey(visitor, handler, node, key) {\n var value = node[key],\n _result;\n if (!value) {\n return;\n }\n var keyHandler = handler && (handler.keys[key] || handler.keys.All);\n var result = void 0;\n if (keyHandler && keyHandler.enter) {\n result = keyHandler.enter.call(null, node, key);\n if (result !== undefined) {\n throw cannotReplaceOrRemoveInKeyHandlerYet(node, key);\n }\n }\n if (Array.isArray(value)) {\n visitArray(visitor, value);\n } else {\n _result = visitNode(visitor, value);\n\n if (_result !== undefined) {\n assignKey(node, key, _result);\n }\n }\n if (keyHandler && keyHandler.exit) {\n result = keyHandler.exit.call(null, node, key);\n if (result !== undefined) {\n throw cannotReplaceOrRemoveInKeyHandlerYet(node, key);\n }\n }\n }\n function visitArray(visitor, array) {\n var i, result;\n\n for (i = 0; i < array.length; i++) {\n result = visitNode(visitor, array[i]);\n\n if (result !== undefined) {\n i += spliceArray(array, i, result) - 1;\n }\n }\n }\n function assignKey(node, key, result) {\n if (result === null) {\n throw cannotRemoveNode(node[key], node, key);\n } else if (Array.isArray(result)) {\n if (result.length === 1) {\n node[key] = result[0];\n } else {\n if (result.length === 0) {\n throw cannotRemoveNode(node[key], node, key);\n } else {\n throw cannotReplaceNode(node[key], node, key);\n }\n }\n } else {\n node[key] = result;\n }\n }\n function spliceArray(array, index, result) {\n if (result === null) {\n array.splice(index, 1);\n return 0;\n } else if (Array.isArray(result)) {\n array.splice.apply(array, [index, 1].concat(result));\n return result.length;\n } else {\n array.splice(index, 1, result);\n return 1;\n }\n }\n function traverse(node, visitor) {\n visitNode(normalizeVisitor(visitor), node);\n }\n function normalizeVisitor(visitor) {\n var normalizedVisitor = {},\n handler,\n normalizedKeys,\n keys,\n keyHandler;\n for (var type in visitor) {\n handler = visitor[type] || visitor.All;\n normalizedKeys = {};\n\n if (typeof handler === 'object') {\n keys = handler.keys;\n\n if (keys) {\n for (var key in keys) {\n keyHandler = keys[key];\n\n if (typeof keyHandler === 'object') {\n normalizedKeys[key] = {\n enter: typeof keyHandler.enter === 'function' ? keyHandler.enter : null,\n exit: typeof keyHandler.exit === 'function' ? keyHandler.exit : null\n };\n } else if (typeof keyHandler === 'function') {\n normalizedKeys[key] = {\n enter: keyHandler,\n exit: null\n };\n }\n }\n }\n normalizedVisitor[type] = {\n enter: typeof handler.enter === 'function' ? handler.enter : null,\n exit: typeof handler.exit === 'function' ? handler.exit : null,\n keys: normalizedKeys\n };\n } else if (typeof handler === 'function') {\n normalizedVisitor[type] = {\n enter: handler,\n exit: null,\n keys: normalizedKeys\n };\n }\n }\n return normalizedVisitor;\n }\n\n function unreachable() {\n throw new Error('unreachable');\n }\n function build(ast) {\n if (!ast) {\n return '';\n }\n var output = [],\n chainBlock,\n body,\n value,\n lines;\n switch (ast.type) {\n case 'Program':\n {\n chainBlock = ast['chained'] && ast.body[0];\n\n if (chainBlock) {\n chainBlock['chained'] = true;\n }\n body = buildEach(ast.body).join('');\n\n output.push(body);\n }\n break;\n case 'ElementNode':\n output.push('<', ast.tag);\n if (ast.attributes.length) {\n output.push(' ', buildEach(ast.attributes).join(' '));\n }\n if (ast.modifiers.length) {\n output.push(' ', buildEach(ast.modifiers).join(' '));\n }\n if (ast.comments.length) {\n output.push(' ', buildEach(ast.comments).join(' '));\n }\n output.push('>');\n output.push.apply(output, buildEach(ast.children));\n output.push('');\n break;\n case 'AttrNode':\n output.push(ast.name, '=');\n value = build(ast.value);\n\n if (ast.value.type === 'TextNode') {\n output.push('\"', value, '\"');\n } else {\n output.push(value);\n }\n break;\n case 'ConcatStatement':\n output.push('\"');\n ast.parts.forEach(function (node) {\n if (node.type === 'StringLiteral') {\n output.push(node.original);\n } else {\n output.push(build(node));\n }\n });\n output.push('\"');\n break;\n case 'TextNode':\n output.push(ast.chars);\n break;\n case 'MustacheStatement':\n {\n output.push(compactJoin(['{{', pathParams(ast), '}}']));\n }\n break;\n case 'MustacheCommentStatement':\n {\n output.push(compactJoin(['{{!--', ast.value, '--}}']));\n }\n break;\n case 'ElementModifierStatement':\n {\n output.push(compactJoin(['{{', pathParams(ast), '}}']));\n }\n break;\n case 'PathExpression':\n output.push(ast.original);\n break;\n case 'SubExpression':\n {\n output.push('(', pathParams(ast), ')');\n }\n break;\n case 'BooleanLiteral':\n output.push(ast.value ? 'true' : 'false');\n break;\n case 'BlockStatement':\n {\n lines = [];\n\n if (ast['chained']) {\n lines.push(['{{else ', pathParams(ast), '}}'].join(''));\n } else {\n lines.push(openBlock(ast));\n }\n lines.push(build(ast.program));\n if (ast.inverse) {\n if (!ast.inverse['chained']) {\n lines.push('{{else}}');\n }\n lines.push(build(ast.inverse));\n }\n if (!ast['chained']) {\n lines.push(closeBlock(ast));\n }\n output.push(lines.join(''));\n }\n break;\n case 'PartialStatement':\n {\n output.push(compactJoin(['{{>', pathParams(ast), '}}']));\n }\n break;\n case 'CommentStatement':\n {\n output.push(compactJoin(['']));\n }\n break;\n case 'StringLiteral':\n {\n output.push('\"' + ast.value + '\"');\n }\n break;\n case 'NumberLiteral':\n {\n output.push(String(ast.value));\n }\n break;\n case 'UndefinedLiteral':\n {\n output.push('undefined');\n }\n break;\n case 'NullLiteral':\n {\n output.push('null');\n }\n break;\n case 'Hash':\n {\n output.push(ast.pairs.map(function (pair) {\n return build(pair);\n }).join(' '));\n }\n break;\n case 'HashPair':\n {\n output.push(ast.key + '=' + build(ast.value));\n }\n break;\n }\n return output.join('');\n }\n function compact(array) {\n var newArray = [];\n array.forEach(function (a) {\n if (typeof a !== 'undefined' && a !== null && a !== '') {\n newArray.push(a);\n }\n });\n return newArray;\n }\n function buildEach(asts) {\n return asts.map(build);\n }\n function pathParams(ast) {\n var path = void 0;\n switch (ast.type) {\n case 'MustacheStatement':\n case 'SubExpression':\n case 'ElementModifierStatement':\n case 'BlockStatement':\n if (isLiteral(ast.path)) {\n return String(ast.path.value);\n }\n path = build(ast.path);\n break;\n case 'PartialStatement':\n path = build(ast.name);\n break;\n default:\n return unreachable();\n }\n return compactJoin([path, buildEach(ast.params).join(' '), build(ast.hash)], ' ');\n }\n function compactJoin(array, delimiter) {\n return compact(array).join(delimiter || '');\n }\n function blockParams(block) {\n var params = block.program.blockParams;\n if (params.length) {\n return ' as |' + params.join(' ') + '|';\n }\n return null;\n }\n function openBlock(block) {\n return ['{{#', pathParams(block), blockParams(block), '}}'].join('');\n }\n function closeBlock(block) {\n return ['{{/', build(block.path), '}}'].join('');\n }\n\n function _classCallCheck$3(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var Walker = function () {\n function Walker(order) {\n _classCallCheck$3(this, Walker);\n\n this.order = order;\n this.stack = [];\n }\n\n Walker.prototype.visit = function (node, callback) {\n if (!node) {\n return;\n }\n this.stack.push(node);\n if (this.order === 'post') {\n this.children(node, callback);\n callback(node, this);\n } else {\n callback(node, this);\n this.children(node, callback);\n }\n this.stack.pop();\n };\n\n Walker.prototype.children = function (node, callback) {\n var visitor = visitors[node.type];\n if (visitor) {\n visitor(this, node, callback);\n }\n };\n\n return Walker;\n }();\n\n var visitors = {\n Program: function (walker, node, callback) {\n var i;\n\n for (i = 0; i < node.body.length; i++) {\n walker.visit(node.body[i], callback);\n }\n },\n ElementNode: function (walker, node, callback) {\n var i;\n\n for (i = 0; i < node.children.length; i++) {\n walker.visit(node.children[i], callback);\n }\n },\n BlockStatement: function (walker, node, callback) {\n walker.visit(node.program, callback);\n walker.visit(node.inverse || null, callback);\n }\n };\n\n function _defaults(obj, defaults) {\n var keys = Object.getOwnPropertyNames(defaults),\n i,\n key,\n value;for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = Object.getOwnPropertyDescriptor(defaults, key);\n if (value && value.configurable && obj[key] === undefined) {\n Object.defineProperty(obj, key, value);\n }\n }return obj;\n }\n\n function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n function _possibleConstructorReturn(self, call) {\n if (!self) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self;\n }\n\n function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass);\n }subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } });if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : _defaults(subClass, superClass);\n }\n\n var voidMap = Object.create(null);\n\n \"area base br col command embed hr img input keygen link meta param source track wbr\".split(\" \").forEach(function (tagName) {\n voidMap[tagName] = true;\n });\n var TokenizerEventHandlers = function (_HandlebarsNodeVisito) {\n _inherits(TokenizerEventHandlers, _HandlebarsNodeVisito);\n\n function TokenizerEventHandlers() {\n _classCallCheck(this, TokenizerEventHandlers);\n\n var _this = _possibleConstructorReturn(this, _HandlebarsNodeVisito.apply(this, arguments));\n\n _this.tagOpenLine = 0;\n _this.tagOpenColumn = 0;\n return _this;\n }\n\n TokenizerEventHandlers.prototype.reset = function () {\n this.currentNode = null;\n };\n // Comment\n\n\n TokenizerEventHandlers.prototype.beginComment = function () {\n this.currentNode = b.comment(\"\");\n this.currentNode.loc = {\n source: null,\n start: b.pos(this.tagOpenLine, this.tagOpenColumn),\n end: null\n };\n };\n\n TokenizerEventHandlers.prototype.appendToCommentData = function (char) {\n this.currentComment.value += char;\n };\n\n TokenizerEventHandlers.prototype.finishComment = function () {\n this.currentComment.loc.end = b.pos(this.tokenizer.line, this.tokenizer.column);\n appendChild(this.currentElement(), this.currentComment);\n };\n // Data\n\n\n TokenizerEventHandlers.prototype.beginData = function () {\n this.currentNode = b.text();\n this.currentNode.loc = {\n source: null,\n start: b.pos(this.tokenizer.line, this.tokenizer.column),\n end: null\n };\n };\n\n TokenizerEventHandlers.prototype.appendToData = function (char) {\n this.currentData.chars += char;\n };\n\n TokenizerEventHandlers.prototype.finishData = function () {\n this.currentData.loc.end = b.pos(this.tokenizer.line, this.tokenizer.column);\n appendChild(this.currentElement(), this.currentData);\n };\n // Tags - basic\n\n\n TokenizerEventHandlers.prototype.tagOpen = function () {\n this.tagOpenLine = this.tokenizer.line;\n this.tagOpenColumn = this.tokenizer.column;\n };\n\n TokenizerEventHandlers.prototype.beginStartTag = function () {\n this.currentNode = {\n type: 'StartTag',\n name: \"\",\n attributes: [],\n modifiers: [],\n comments: [],\n selfClosing: false,\n loc: SYNTHETIC\n };\n };\n\n TokenizerEventHandlers.prototype.beginEndTag = function () {\n this.currentNode = {\n type: 'EndTag',\n name: \"\",\n attributes: [],\n modifiers: [],\n comments: [],\n selfClosing: false,\n loc: SYNTHETIC\n };\n };\n\n TokenizerEventHandlers.prototype.finishTag = function () {\n var _tokenizer = this.tokenizer,\n line = _tokenizer.line,\n column = _tokenizer.column;\n\n var tag = this.currentTag;\n tag.loc = b.loc(this.tagOpenLine, this.tagOpenColumn, line, column);\n if (tag.type === 'StartTag') {\n this.finishStartTag();\n if (voidMap[tag.name] || tag.selfClosing) {\n this.finishEndTag(true);\n }\n } else if (tag.type === 'EndTag') {\n this.finishEndTag(false);\n }\n };\n\n TokenizerEventHandlers.prototype.finishStartTag = function () {\n var _currentStartTag = this.currentStartTag,\n name = _currentStartTag.name,\n attributes = _currentStartTag.attributes,\n modifiers = _currentStartTag.modifiers,\n comments = _currentStartTag.comments;\n\n var loc = b.loc(this.tagOpenLine, this.tagOpenColumn);\n var element = b.element(name, attributes, modifiers, [], comments, loc);\n this.elementStack.push(element);\n };\n\n TokenizerEventHandlers.prototype.finishEndTag = function (isVoid) {\n var tag = this.currentTag;\n var element = this.elementStack.pop();\n var parent = this.currentElement();\n validateEndTag(tag, element, isVoid);\n element.loc.end.line = this.tokenizer.line;\n element.loc.end.column = this.tokenizer.column;\n parseElementBlockParams(element);\n appendChild(parent, element);\n };\n\n TokenizerEventHandlers.prototype.markTagAsSelfClosing = function () {\n this.currentTag.selfClosing = true;\n };\n // Tags - name\n\n\n TokenizerEventHandlers.prototype.appendToTagName = function (char) {\n this.currentTag.name += char;\n };\n // Tags - attributes\n\n\n TokenizerEventHandlers.prototype.beginAttribute = function () {\n var tag = this.currentTag;\n if (tag.type === 'EndTag') {\n throw new SyntaxError(\"Invalid end tag: closing tag must not have attributes, \" + (\"in `\" + tag.name + \"` (on line \" + this.tokenizer.line + \").\"), tag.loc);\n }\n this.currentAttribute = {\n name: \"\",\n parts: [],\n isQuoted: false,\n isDynamic: false,\n start: b.pos(this.tokenizer.line, this.tokenizer.column),\n valueStartLine: 0,\n valueStartColumn: 0\n };\n };\n\n TokenizerEventHandlers.prototype.appendToAttributeName = function (char) {\n this.currentAttr.name += char;\n };\n\n TokenizerEventHandlers.prototype.beginAttributeValue = function (isQuoted) {\n this.currentAttr.isQuoted = isQuoted;\n this.currentAttr.valueStartLine = this.tokenizer.line;\n this.currentAttr.valueStartColumn = this.tokenizer.column;\n };\n\n TokenizerEventHandlers.prototype.appendToAttributeValue = function (char) {\n var parts = this.currentAttr.parts,\n loc,\n text;\n var lastPart = parts[parts.length - 1];\n if (lastPart && lastPart.type === 'TextNode') {\n lastPart.chars += char;\n // update end location for each added char\n lastPart.loc.end.line = this.tokenizer.line;\n lastPart.loc.end.column = this.tokenizer.column;\n } else {\n // initially assume the text node is a single char\n loc = b.loc(this.tokenizer.line, this.tokenizer.column, this.tokenizer.line, this.tokenizer.column);\n // correct for `\\n` as first char\n\n if (char === '\\n') {\n loc.start.line -= 1;\n loc.start.column = lastPart ? lastPart.loc.end.column : this.currentAttr.valueStartColumn;\n }\n text = b.text(char, loc);\n\n parts.push(text);\n }\n };\n\n TokenizerEventHandlers.prototype.finishAttributeValue = function () {\n var _currentAttr = this.currentAttr,\n name = _currentAttr.name,\n parts = _currentAttr.parts,\n isQuoted = _currentAttr.isQuoted,\n isDynamic = _currentAttr.isDynamic,\n valueStartLine = _currentAttr.valueStartLine,\n valueStartColumn = _currentAttr.valueStartColumn;\n\n var value = assembleAttributeValue(parts, isQuoted, isDynamic, this.tokenizer.line);\n value.loc = b.loc(valueStartLine, valueStartColumn, this.tokenizer.line, this.tokenizer.column);\n var loc = b.loc(this.currentAttr.start.line, this.currentAttr.start.column, this.tokenizer.line, this.tokenizer.column);\n var attribute = b.attr(name, value, loc);\n this.currentStartTag.attributes.push(attribute);\n };\n\n TokenizerEventHandlers.prototype.reportSyntaxError = function (message) {\n throw new SyntaxError(\"Syntax error at line \" + this.tokenizer.line + \" col \" + this.tokenizer.column + \": \" + message, b.loc(this.tokenizer.line, this.tokenizer.column));\n };\n\n return TokenizerEventHandlers;\n }(HandlebarsNodeVisitors);\n\n function assembleAttributeValue(parts, isQuoted, isDynamic, line) {\n if (isDynamic) {\n if (isQuoted) {\n return assembleConcatenatedValue(parts);\n } else {\n if (parts.length === 1 || parts.length === 2 && parts[1].type === 'TextNode' && parts[1].chars === '/') {\n return parts[0];\n } else {\n throw new SyntaxError(\"An unquoted attribute value must be a string or a mustache, \" + \"preceeded by whitespace or a '=' character, and \" + (\"followed by whitespace, a '>' character, or '/>' (on line \" + line + \")\"), b.loc(line, 0));\n }\n }\n } else {\n return parts.length > 0 ? parts[0] : b.text(\"\");\n }\n }\n function assembleConcatenatedValue(parts) {\n var i, part;\n\n for (i = 0; i < parts.length; i++) {\n part = parts[i];\n\n if (part.type !== 'MustacheStatement' && part.type !== 'TextNode') {\n throw new SyntaxError(\"Unsupported node in quoted attribute value: \" + part['type'], part.loc);\n }\n }\n return b.concat(parts);\n }\n function validateEndTag(tag, element, selfClosing) {\n var error = void 0;\n if (voidMap[tag.name] && !selfClosing) {\n // EngTag is also called by StartTag for void and self-closing tags (i.e.\n // or
, so we need to check for that here. Otherwise, we would\n // throw an error for those cases.\n error = \"Invalid end tag \" + formatEndTagInfo(tag) + \" (void elements cannot have end tags).\";\n } else if (element.tag === undefined) {\n error = \"Closing tag \" + formatEndTagInfo(tag) + \" without an open tag.\";\n } else if (element.tag !== tag.name) {\n error = \"Closing tag \" + formatEndTagInfo(tag) + \" did not match last open tag `\" + element.tag + \"` (on line \" + element.loc.start.line + \").\";\n }\n if (error) {\n throw new SyntaxError(error, element.loc);\n }\n }\n function formatEndTagInfo(tag) {\n return \"`\" + tag.name + \"` (on line \" + tag.loc.end.line + \")\";\n }\n var syntax = {\n parse: preprocess,\n builders: b,\n print: build,\n traverse: traverse,\n Walker: Walker\n };\n function preprocess(html, options) {\n var ast = typeof html === 'object' ? html : (0, _handlebars.parse)(html),\n i,\n l,\n transform,\n env,\n pluginResult;\n var program = new TokenizerEventHandlers(html, options).acceptNode(ast);\n if (options && options.plugins && options.plugins.ast) {\n for (i = 0, l = options.plugins.ast.length; i < l; i++) {\n transform = options.plugins.ast[i];\n env = (0, _util.assign)({}, options, { syntax: syntax }, { plugins: undefined });\n pluginResult = transform(env);\n\n traverse(program, pluginResult.visitors);\n }\n }\n return program;\n }\n\n // used by ember-compiler\n // AST\n\n exports.AST = nodes;\n exports.preprocess = preprocess;\n exports.builders = b;\n exports.traverse = traverse;\n exports.Walker = Walker;\n exports.print = build;\n exports.SyntaxError = SyntaxError;\n exports.isLiteral = isLiteral$1;\n exports.printLiteral = printLiteral;\n});","enifed('@glimmer/util', ['exports'], function (exports) {\n 'use strict';\n\n // There is a small whitelist of namespaced attributes specially\n // enumerated in\n // https://www.w3.org/TR/html/syntax.html#attributes-0\n //\n // > When a foreign element has one of the namespaced attributes given by\n // > the local name and namespace of the first and second cells of a row\n // > from the following table, it must be written using the name given by\n // > the third cell from the same row.\n //\n // In all other cases, colons are interpreted as a regular character\n // with no special meaning:\n //\n // > No other namespaced attribute can be expressed in the HTML syntax.\n\n var XLINK = 'http://www.w3.org/1999/xlink';\n var XML = 'http://www.w3.org/XML/1998/namespace';\n var XMLNS = 'http://www.w3.org/2000/xmlns/';\n var WHITELIST = {\n 'xlink:actuate': XLINK,\n 'xlink:arcrole': XLINK,\n 'xlink:href': XLINK,\n 'xlink:role': XLINK,\n 'xlink:show': XLINK,\n 'xlink:title': XLINK,\n 'xlink:type': XLINK,\n 'xml:base': XML,\n 'xml:lang': XML,\n 'xml:space': XML,\n 'xmlns': XMLNS,\n 'xmlns:xlink': XMLNS\n };\n\n // import Logger from './logger';\n // let alreadyWarned = false;\n // import Logger from './logger';\n\n\n function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var LogLevel;\n (function (LogLevel) {\n LogLevel[LogLevel[\"Trace\"] = 0] = \"Trace\";\n LogLevel[LogLevel[\"Debug\"] = 1] = \"Debug\";\n LogLevel[LogLevel[\"Warn\"] = 2] = \"Warn\";\n LogLevel[LogLevel[\"Error\"] = 3] = \"Error\";\n })(LogLevel || (exports.LogLevel = LogLevel = {}));\n\n var NullConsole = function () {\n function NullConsole() {\n _classCallCheck(this, NullConsole);\n }\n\n NullConsole.prototype.log = function () {};\n\n NullConsole.prototype.warn = function () {};\n\n NullConsole.prototype.error = function () {};\n\n NullConsole.prototype.trace = function () {};\n\n return NullConsole;\n }();\n\n var ALWAYS = void 0;\n var Logger = function () {\n function Logger(_ref) {\n var console = _ref.console,\n level = _ref.level;\n\n _classCallCheck(this, Logger);\n\n this.f = ALWAYS;\n this.force = ALWAYS;\n this.console = console;\n this.level = level;\n }\n\n Logger.prototype.skipped = function (level) {\n return level < this.level;\n };\n\n Logger.prototype.trace = function (message) {\n var _ref2 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n _ref2$stackTrace = _ref2.stackTrace,\n stackTrace = _ref2$stackTrace === undefined ? false : _ref2$stackTrace;\n\n if (this.skipped(LogLevel.Trace)) return;\n this.console.log(message);\n if (stackTrace) this.console.trace();\n };\n\n Logger.prototype.debug = function (message) {\n var _ref3 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n _ref3$stackTrace = _ref3.stackTrace,\n stackTrace = _ref3$stackTrace === undefined ? false : _ref3$stackTrace;\n\n if (this.skipped(LogLevel.Debug)) return;\n this.console.log(message);\n if (stackTrace) this.console.trace();\n };\n\n Logger.prototype.warn = function (message) {\n var _ref4 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n _ref4$stackTrace = _ref4.stackTrace,\n stackTrace = _ref4$stackTrace === undefined ? false : _ref4$stackTrace;\n\n if (this.skipped(LogLevel.Warn)) return;\n this.console.warn(message);\n if (stackTrace) this.console.trace();\n };\n\n Logger.prototype.error = function (message) {\n if (this.skipped(LogLevel.Error)) return;\n this.console.error(message);\n };\n\n return Logger;\n }();\n var _console = typeof console === 'undefined' ? new NullConsole() : console;\n ALWAYS = new Logger({ console: _console, level: LogLevel.Trace });\n var LOG_LEVEL = LogLevel.Debug;\n var logger = new Logger({ console: _console, level: LOG_LEVEL });\n\n var objKeys = Object.keys;\n\n var GUID = 0;\n function initializeGuid(object) {\n return object._guid = ++GUID;\n }\n function ensureGuid(object) {\n return object._guid || initializeGuid(object);\n }\n\n function _classCallCheck$1(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var proto = Object.create(null, {\n // without this, we will always still end up with (new\n // EmptyObject()).constructor === Object\n constructor: {\n value: undefined,\n enumerable: false,\n writable: true\n }\n });\n function EmptyObject() {}\n EmptyObject.prototype = proto;\n function dict() {\n // let d = Object.create(null);\n // d.x = 1;\n // delete d.x;\n // return d;\n return new EmptyObject();\n }\n var DictSet = function () {\n function DictSet() {\n _classCallCheck$1(this, DictSet);\n\n this.dict = dict();\n }\n\n DictSet.prototype.add = function (obj) {\n if (typeof obj === 'string') this.dict[obj] = obj;else this.dict[ensureGuid(obj)] = obj;\n return this;\n };\n\n DictSet.prototype.delete = function (obj) {\n if (typeof obj === 'string') delete this.dict[obj];else if (obj._guid) delete this.dict[obj._guid];\n };\n\n DictSet.prototype.forEach = function (callback) {\n var dict = this.dict,\n i;\n\n var dictKeys = Object.keys(dict);\n for (i = 0; dictKeys.length; i++) {\n callback(dict[dictKeys[i]]);\n }\n };\n\n DictSet.prototype.toArray = function () {\n return Object.keys(this.dict);\n };\n\n return DictSet;\n }();\n var Stack = function () {\n function Stack() {\n _classCallCheck$1(this, Stack);\n\n this.stack = [];\n this.current = null;\n }\n\n Stack.prototype.toArray = function () {\n return this.stack;\n };\n\n Stack.prototype.push = function (item) {\n this.current = item;\n this.stack.push(item);\n };\n\n Stack.prototype.pop = function () {\n var item = this.stack.pop();\n var len = this.stack.length;\n this.current = len === 0 ? null : this.stack[len - 1];\n return item === undefined ? null : item;\n };\n\n Stack.prototype.isEmpty = function () {\n return this.stack.length === 0;\n };\n\n return Stack;\n }();\n\n function _classCallCheck$2(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n var LinkedList = function () {\n function LinkedList() {\n _classCallCheck$2(this, LinkedList);\n\n this.clear();\n }\n\n LinkedList.fromSlice = function (slice) {\n var list = new LinkedList();\n slice.forEachNode(function (n) {\n return list.append(n.clone());\n });\n return list;\n };\n\n LinkedList.prototype.head = function () {\n return this._head;\n };\n\n LinkedList.prototype.tail = function () {\n return this._tail;\n };\n\n LinkedList.prototype.clear = function () {\n this._head = this._tail = null;\n };\n\n LinkedList.prototype.isEmpty = function () {\n return this._head === null;\n };\n\n LinkedList.prototype.toArray = function () {\n var out = [];\n this.forEachNode(function (n) {\n return out.push(n);\n });\n return out;\n };\n\n LinkedList.prototype.splice = function (start, end, reference) {\n var before = void 0;\n if (reference === null) {\n before = this._tail;\n this._tail = end;\n } else {\n before = reference.prev;\n end.next = reference;\n reference.prev = end;\n }\n if (before) {\n before.next = start;\n start.prev = before;\n }\n };\n\n LinkedList.prototype.nextNode = function (node) {\n return node.next;\n };\n\n LinkedList.prototype.prevNode = function (node) {\n return node.prev;\n };\n\n LinkedList.prototype.forEachNode = function (callback) {\n var node = this._head;\n while (node !== null) {\n callback(node);\n node = node.next;\n }\n };\n\n LinkedList.prototype.contains = function (needle) {\n var node = this._head;\n while (node !== null) {\n if (node === needle) return true;\n node = node.next;\n }\n return false;\n };\n\n LinkedList.prototype.insertBefore = function (node) {\n var reference = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n\n if (reference === null) return this.append(node);\n if (reference.prev) reference.prev.next = node;else this._head = node;\n node.prev = reference.prev;\n node.next = reference;\n reference.prev = node;\n return node;\n };\n\n LinkedList.prototype.append = function (node) {\n var tail = this._tail;\n if (tail) {\n tail.next = node;\n node.prev = tail;\n node.next = null;\n } else {\n this._head = node;\n }\n return this._tail = node;\n };\n\n LinkedList.prototype.pop = function () {\n if (this._tail) return this.remove(this._tail);\n return null;\n };\n\n LinkedList.prototype.prepend = function (node) {\n if (this._head) return this.insertBefore(node, this._head);\n return this._head = this._tail = node;\n };\n\n LinkedList.prototype.remove = function (node) {\n if (node.prev) node.prev.next = node.next;else this._head = node.next;\n if (node.next) node.next.prev = node.prev;else this._tail = node.prev;\n return node;\n };\n\n return LinkedList;\n }();\n var ListSlice = function () {\n function ListSlice(head, tail) {\n _classCallCheck$2(this, ListSlice);\n\n this._head = head;\n this._tail = tail;\n }\n\n ListSlice.toList = function (slice) {\n var list = new LinkedList();\n slice.forEachNode(function (n) {\n return list.append(n.clone());\n });\n return list;\n };\n\n ListSlice.prototype.forEachNode = function (callback) {\n var node = this._head;\n while (node !== null) {\n callback(node);\n node = this.nextNode(node);\n }\n };\n\n ListSlice.prototype.contains = function (needle) {\n var node = this._head;\n while (node !== null) {\n if (node === needle) return true;\n node = node.next;\n }\n return false;\n };\n\n ListSlice.prototype.head = function () {\n return this._head;\n };\n\n ListSlice.prototype.tail = function () {\n return this._tail;\n };\n\n ListSlice.prototype.toArray = function () {\n var out = [];\n this.forEachNode(function (n) {\n return out.push(n);\n });\n return out;\n };\n\n ListSlice.prototype.nextNode = function (node) {\n if (node === this._tail) return null;\n return node.next;\n };\n\n ListSlice.prototype.prevNode = function (node) {\n if (node === this._head) return null;\n return node.prev;\n };\n\n ListSlice.prototype.isEmpty = function () {\n return false;\n };\n\n return ListSlice;\n }();\n var EMPTY_SLICE = new ListSlice(null, null);\n\n var HAS_NATIVE_WEAKMAP = function () {\n // detect if `WeakMap` is even present\n var hasWeakMap = typeof WeakMap === 'function';\n if (!hasWeakMap) {\n return false;\n }\n var instance = new WeakMap();\n // use `Object`'s `.toString` directly to prevent us from detecting\n // polyfills as native weakmaps\n return Object.prototype.toString.call(instance) === '[object WeakMap]';\n }();\n\n var HAS_TYPED_ARRAYS = typeof Uint32Array !== 'undefined';\n var A = void 0;\n if (HAS_TYPED_ARRAYS) {\n A = Uint32Array;\n } else {\n A = Array;\n }\n var A$1 = A;\n var EMPTY_ARRAY = HAS_NATIVE_WEAKMAP ? Object.freeze([]) : [];\n\n exports.getAttrNamespace = function (attrName) {\n return WHITELIST[attrName] || null;\n };\n exports.assert = function (test, msg) {\n // if (!alreadyWarned) {\n // alreadyWarned = true;\n // Logger.warn(\"Don't leave debug assertions on in public builds\");\n // }\n if (!test) {\n throw new Error(msg || \"assertion failure\");\n }\n };\n exports.LOGGER = logger;\n exports.Logger = Logger;\n exports.LogLevel = LogLevel;\n exports.assign = function (obj) {\n var i, assignment, keys, j, key;\n\n for (i = 1; i < arguments.length; i++) {\n assignment = arguments[i];\n\n if (assignment === null || typeof assignment !== 'object') continue;\n keys = objKeys(assignment);\n\n for (j = 0; j < keys.length; j++) {\n key = keys[j];\n\n obj[key] = assignment[key];\n }\n }\n return obj;\n };\n exports.fillNulls = function (count) {\n var arr = new Array(count),\n i;\n for (i = 0; i < count; i++) {\n arr[i] = null;\n }\n return arr;\n };\n exports.ensureGuid = ensureGuid;\n exports.initializeGuid = initializeGuid;\n exports.Stack = Stack;\n exports.DictSet = DictSet;\n exports.dict = dict;\n exports.EMPTY_SLICE = EMPTY_SLICE;\n exports.LinkedList = LinkedList;\n exports.ListNode = function ListNode(value) {\n _classCallCheck$2(this, ListNode);\n\n this.next = null;\n this.prev = null;\n this.value = value;\n };\n exports.ListSlice = ListSlice;\n exports.A = A$1;\n exports.EMPTY_ARRAY = EMPTY_ARRAY;\n exports.HAS_NATIVE_WEAKMAP = HAS_NATIVE_WEAKMAP;\n exports.unwrap = function (val) {\n if (val === null || val === undefined) throw new Error('Expected value to be present');\n return val;\n };\n exports.expect = function (val, message) {\n if (val === null || val === undefined) throw new Error(message);\n return val;\n };\n exports.unreachable = function () {\n return new Error('unreachable');\n };\n exports.typePos = function (lastOperand) {\n return lastOperand - 4;\n };\n});","enifed(\"@glimmer/wire-format\", [\"exports\"], function (exports) {\n \"use strict\";\n\n var Opcodes;\n (function (Opcodes) {\n // Statements\n Opcodes[Opcodes[\"Text\"] = 0] = \"Text\";\n Opcodes[Opcodes[\"Append\"] = 1] = \"Append\";\n Opcodes[Opcodes[\"Comment\"] = 2] = \"Comment\";\n Opcodes[Opcodes[\"Modifier\"] = 3] = \"Modifier\";\n Opcodes[Opcodes[\"Block\"] = 4] = \"Block\";\n Opcodes[Opcodes[\"Component\"] = 5] = \"Component\";\n Opcodes[Opcodes[\"OpenElement\"] = 6] = \"OpenElement\";\n Opcodes[Opcodes[\"FlushElement\"] = 7] = \"FlushElement\";\n Opcodes[Opcodes[\"CloseElement\"] = 8] = \"CloseElement\";\n Opcodes[Opcodes[\"StaticAttr\"] = 9] = \"StaticAttr\";\n Opcodes[Opcodes[\"DynamicAttr\"] = 10] = \"DynamicAttr\";\n Opcodes[Opcodes[\"Yield\"] = 11] = \"Yield\";\n Opcodes[Opcodes[\"Partial\"] = 12] = \"Partial\";\n Opcodes[Opcodes[\"DynamicArg\"] = 13] = \"DynamicArg\";\n Opcodes[Opcodes[\"StaticArg\"] = 14] = \"StaticArg\";\n Opcodes[Opcodes[\"TrustingAttr\"] = 15] = \"TrustingAttr\";\n Opcodes[Opcodes[\"Debugger\"] = 16] = \"Debugger\";\n Opcodes[Opcodes[\"ClientSideStatement\"] = 17] = \"ClientSideStatement\";\n // Expressions\n Opcodes[Opcodes[\"Unknown\"] = 18] = \"Unknown\";\n Opcodes[Opcodes[\"Get\"] = 19] = \"Get\";\n Opcodes[Opcodes[\"MaybeLocal\"] = 20] = \"MaybeLocal\";\n Opcodes[Opcodes[\"FixThisBeforeWeMerge\"] = 21] = \"FixThisBeforeWeMerge\";\n Opcodes[Opcodes[\"HasBlock\"] = 22] = \"HasBlock\";\n Opcodes[Opcodes[\"HasBlockParams\"] = 23] = \"HasBlockParams\";\n Opcodes[Opcodes[\"Undefined\"] = 24] = \"Undefined\";\n Opcodes[Opcodes[\"Helper\"] = 25] = \"Helper\";\n Opcodes[Opcodes[\"Concat\"] = 26] = \"Concat\";\n Opcodes[Opcodes[\"ClientSideExpression\"] = 27] = \"ClientSideExpression\";\n })(Opcodes || (exports.Ops = Opcodes = {}));\n\n function is(variant) {\n return function (value) {\n return Array.isArray(value) && value[0] === variant;\n };\n }\n var Expressions;\n (function (Expressions) {\n Expressions.isUnknown = is(Opcodes.Unknown);\n Expressions.isGet = is(Opcodes.Get);\n Expressions.isConcat = is(Opcodes.Concat);\n Expressions.isHelper = is(Opcodes.Helper);\n Expressions.isHasBlock = is(Opcodes.HasBlock);\n Expressions.isHasBlockParams = is(Opcodes.HasBlockParams);\n Expressions.isUndefined = is(Opcodes.Undefined);\n Expressions.isClientSide = is(Opcodes.ClientSideExpression);\n Expressions.isMaybeLocal = is(Opcodes.MaybeLocal);\n\n Expressions.isPrimitiveValue = function (value) {\n if (value === null) {\n return true;\n }\n return typeof value !== 'object';\n };\n })(Expressions || (exports.Expressions = Expressions = {}));\n var Statements;\n (function (Statements) {\n Statements.isText = is(Opcodes.Text);\n Statements.isAppend = is(Opcodes.Append);\n Statements.isComment = is(Opcodes.Comment);\n Statements.isModifier = is(Opcodes.Modifier);\n Statements.isBlock = is(Opcodes.Block);\n Statements.isComponent = is(Opcodes.Component);\n Statements.isOpenElement = is(Opcodes.OpenElement);\n Statements.isFlushElement = is(Opcodes.FlushElement);\n Statements.isCloseElement = is(Opcodes.CloseElement);\n Statements.isStaticAttr = is(Opcodes.StaticAttr);\n Statements.isDynamicAttr = is(Opcodes.DynamicAttr);\n Statements.isYield = is(Opcodes.Yield);\n Statements.isPartial = is(Opcodes.Partial);\n Statements.isDynamicArg = is(Opcodes.DynamicArg);\n Statements.isStaticArg = is(Opcodes.StaticArg);\n Statements.isTrustingAttr = is(Opcodes.TrustingAttr);\n Statements.isDebugger = is(Opcodes.Debugger);\n Statements.isClientSide = is(Opcodes.ClientSideStatement);\n function isAttribute(val) {\n return val[0] === Opcodes.StaticAttr || val[0] === Opcodes.DynamicAttr || val[0] === Opcodes.TrustingAttr;\n }\n Statements.isAttribute = isAttribute;\n function isArgument(val) {\n return val[0] === Opcodes.StaticArg || val[0] === Opcodes.DynamicArg;\n }\n Statements.isArgument = isArgument;\n\n Statements.isParameter = function (val) {\n return isAttribute(val) || isArgument(val);\n };\n\n Statements.getParameterName = function (s) {\n return s[1];\n };\n })(Statements || (exports.Statements = Statements = {}));\n\n exports.is = is;\n exports.Expressions = Expressions;\n exports.Statements = Statements;\n exports.Ops = Opcodes;\n});","enifed('backburner', ['exports'], function (exports) {\n 'use strict';\n\n var NUMBER = /\\d+/;\n function isString(suspect) {\n return typeof suspect === 'string';\n }\n function isFunction(suspect) {\n return typeof suspect === 'function';\n }\n function isNumber(suspect) {\n return typeof suspect === 'number';\n }\n function isCoercableNumber(suspect) {\n return isNumber(suspect) && suspect === suspect || NUMBER.test(suspect);\n }\n function noSuchQueue(name) {\n throw new Error('You attempted to schedule an action in a queue (' + name + ') that doesn\\'t exist');\n }\n function noSuchMethod(name) {\n throw new Error('You attempted to schedule an action in a queue (' + name + ') for a method that doesn\\'t exist');\n }\n function getOnError(options) {\n return options.onError || options.onErrorTarget && options.onErrorTarget[options.onErrorMethod];\n }\n function findItem(target, method, collection) {\n var index = -1,\n i,\n l;\n for (i = 0, l = collection.length; i < l; i += 4) {\n if (collection[i] === target && collection[i + 1] === method) {\n index = i;\n break;\n }\n }\n return index;\n }\n function findTimer(timer, collection) {\n var index = -1,\n i;\n for (i = 3; i < collection.length; i += 4) {\n if (collection[i] === timer) {\n index = i - 3;\n break;\n }\n }\n return index;\n }\n\n function binarySearch(time, timers) {\n var start = 0;\n var end = timers.length - 2;\n var middle = void 0;\n var l = void 0;\n while (start < end) {\n // since timers is an array of pairs 'l' will always\n // be an integer\n l = (end - start) / 2;\n // compensate for the index in case even number\n // of pairs inside timers\n middle = start + l - l % 2;\n if (time >= timers[middle]) {\n start = middle + 2;\n } else {\n end = middle;\n }\n }\n return time >= timers[start] ? start + 2 : start;\n }\n\n var Queue = function () {\n function Queue(name) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var globalOptions = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n\n\n this._queueBeingFlushed = [];\n this.targetQueues = Object.create(null);\n this.index = 0;\n this._queue = [];\n this.name = name;\n this.options = options;\n this.globalOptions = globalOptions;\n }\n\n Queue.prototype.push = function (target, method, args, stack) {\n this._queue.push(target, method, args, stack);\n return {\n queue: this,\n target: target,\n method: method\n };\n };\n\n Queue.prototype.pushUnique = function (target, method, args, stack) {\n var guid = this.guidForTarget(target);\n if (guid) {\n this.pushUniqueWithGuid(guid, target, method, args, stack);\n } else {\n this.pushUniqueWithoutGuid(target, method, args, stack);\n }\n return {\n queue: this,\n target: target,\n method: method\n };\n };\n\n Queue.prototype.flush = function (sync) {\n var _options = this.options,\n before = _options.before,\n after = _options.after,\n onError,\n i;\n\n var target = void 0;\n var method = void 0;\n var args = void 0;\n var errorRecordedForStack = void 0;\n this.targetQueues = Object.create(null);\n if (this._queueBeingFlushed.length === 0) {\n this._queueBeingFlushed = this._queue;\n this._queue = [];\n }\n if (before !== undefined) {\n before();\n }\n var invoke = void 0;\n var queueItems = this._queueBeingFlushed;\n if (queueItems.length > 0) {\n onError = getOnError(this.globalOptions);\n\n invoke = onError ? this.invokeWithOnError : this.invoke;\n for (i = this.index; i < queueItems.length; i += 4) {\n this.index += 4;\n method = queueItems[i + 1];\n // method could have been nullified / canceled during flush\n if (method !== null) {\n //\n // ** Attention intrepid developer **\n //\n // To find out the stack of this task when it was scheduled onto\n // the run loop, add the following to your app.js:\n //\n // Ember.run.backburner.DEBUG = true; // NOTE: This slows your app, don't leave it on in production.\n //\n // Once that is in place, when you are at a breakpoint and navigate\n // here in the stack explorer, you can look at `errorRecordedForStack.stack`,\n // which will be the captured stack when this job was scheduled.\n //\n // One possible long-term solution is the following Chrome issue:\n // https://bugs.chromium.org/p/chromium/issues/detail?id=332624\n //\n target = queueItems[i];\n args = queueItems[i + 2];\n errorRecordedForStack = queueItems[i + 3]; // Debugging assistance\n invoke(target, method, args, onError, errorRecordedForStack);\n }\n if (this.index !== this._queueBeingFlushed.length && this.globalOptions.mustYield && this.globalOptions.mustYield()) {\n return 1 /* Pause */;\n }\n }\n }\n if (after !== undefined) {\n after();\n }\n this._queueBeingFlushed.length = 0;\n this.index = 0;\n if (sync !== false && this._queue.length > 0) {\n // check if new items have been added\n this.flush(true);\n }\n };\n\n Queue.prototype.hasWork = function () {\n return this._queueBeingFlushed.length > 0 || this._queue.length > 0;\n };\n\n Queue.prototype.cancel = function (_ref) {\n var target = _ref.target,\n method = _ref.method,\n t,\n i,\n l;\n\n var queue = this._queue;\n var guid = this.guidForTarget(target);\n var targetQueue = guid ? this.targetQueues[guid] : undefined;\n if (targetQueue !== undefined) {\n t = void 0;\n\n for (i = 0, l = targetQueue.length; i < l; i += 2) {\n t = targetQueue[i];\n if (t === method) {\n targetQueue.splice(i, 2);\n break;\n }\n }\n }\n var index = findItem(target, method, queue);\n if (index > -1) {\n queue.splice(index, 4);\n return true;\n }\n // if not found in current queue\n // could be in the queue that is being flushed\n queue = this._queueBeingFlushed;\n index = findItem(target, method, queue);\n if (index > -1) {\n queue[index + 1] = null;\n return true;\n }\n return false;\n };\n\n Queue.prototype.guidForTarget = function (target) {\n if (!target) {\n return;\n }\n var peekGuid = this.globalOptions.peekGuid;\n if (peekGuid) {\n return peekGuid(target);\n }\n var KEY = this.globalOptions.GUID_KEY;\n if (KEY) {\n return target[KEY];\n }\n };\n\n Queue.prototype.pushUniqueWithoutGuid = function (target, method, args, stack) {\n var queue = this._queue;\n var index = findItem(target, method, queue);\n if (index > -1) {\n queue[index + 2] = args; // replace args\n queue[index + 3] = stack; // replace stack\n } else {\n queue.push(target, method, args, stack);\n }\n };\n\n Queue.prototype.targetQueue = function (_targetQueue, target, method, args, stack) {\n var queue = this._queue,\n i,\n l,\n currentMethod,\n currentIndex;\n for (i = 0, l = _targetQueue.length; i < l; i += 2) {\n currentMethod = _targetQueue[i];\n\n if (currentMethod === method) {\n currentIndex = _targetQueue[i + 1];\n\n queue[currentIndex + 2] = args; // replace args\n queue[currentIndex + 3] = stack; // replace stack\n return;\n }\n }\n _targetQueue.push(method, queue.push(target, method, args, stack) - 4);\n };\n\n Queue.prototype.pushUniqueWithGuid = function (guid, target, method, args, stack) {\n var localQueue = this.targetQueues[guid];\n if (localQueue !== undefined) {\n this.targetQueue(localQueue, target, method, args, stack);\n } else {\n this.targetQueues[guid] = [method, this._queue.push(target, method, args, stack) - 4];\n }\n };\n\n Queue.prototype.invoke = function (target, method, args /*, onError, errorRecordedForStack */) {\n if (args !== undefined) {\n method.apply(target, args);\n } else {\n method.call(target);\n }\n };\n\n Queue.prototype.invokeWithOnError = function (target, method, args, onError, errorRecordedForStack) {\n try {\n if (args !== undefined) {\n method.apply(target, args);\n } else {\n method.call(target);\n }\n } catch (error) {\n onError(error, errorRecordedForStack);\n }\n };\n\n return Queue;\n }();\n\n var DeferredActionQueues = function () {\n function DeferredActionQueues() {\n var queueNames = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n var options = arguments[1];\n\n\n this.queues = {};\n this.queueNameIndex = 0;\n this.queueNames = queueNames;\n queueNames.reduce(function (queues, queueName) {\n queues[queueName] = new Queue(queueName, options[queueName], options);\n return queues;\n }, this.queues);\n }\n /*\n @method schedule\n @param {String} queueName\n @param {Any} target\n @param {Any} method\n @param {Any} args\n @param {Boolean} onceFlag\n @param {Any} stack\n @return queue\n */\n\n DeferredActionQueues.prototype.schedule = function (queueName, target, method, args, onceFlag, stack) {\n var queues = this.queues;\n var queue = queues[queueName];\n if (!queue) {\n noSuchQueue(queueName);\n }\n if (!method) {\n noSuchMethod(queueName);\n }\n if (onceFlag) {\n return queue.pushUnique(target, method, args, stack);\n } else {\n return queue.push(target, method, args, stack);\n }\n };\n\n DeferredActionQueues.prototype.flush = function () {\n var queue = void 0;\n var queueName = void 0;\n var numberOfQueues = this.queueNames.length;\n while (this.queueNameIndex < numberOfQueues) {\n queueName = this.queueNames[this.queueNameIndex];\n queue = this.queues[queueName];\n if (queue.hasWork() === false) {\n this.queueNameIndex++;\n } else {\n if (queue.flush(false /* async */) === 1 /* Pause */) {\n return 1 /* Pause */;\n }\n this.queueNameIndex = 0; // only reset to first queue if non-pause break\n }\n }\n };\n\n return DeferredActionQueues;\n }();\n\n // accepts a function that when invoked will return an iterator\n // iterator will drain until completion\n var iteratorDrain = function (fn) {\n var iterator = fn();\n var result = iterator.next();\n while (result.done === false) {\n result.value();\n result = iterator.next();\n }\n };\n\n var noop = function () {};\n var SET_TIMEOUT = setTimeout;\n function parseArgs() {\n var length = arguments.length,\n i;\n var method = void 0;\n var target = void 0;\n var args = void 0;\n if (length === 1) {\n method = arguments[0];\n target = null;\n } else {\n target = arguments[0];\n method = arguments[1];\n if (isString(method)) {\n method = target[method];\n }\n if (length > 2) {\n args = new Array(length - 2);\n for (i = 0; i < length - 2; i++) {\n args[i] = arguments[i + 2];\n }\n }\n }\n return [target, method, args];\n }\n\n var Backburner = function () {\n function Backburner(queueNames) {\n var _this = this;\n\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n\n this.DEBUG = false;\n this.currentInstance = null;\n this._timerTimeoutId = null;\n this._autorun = null;\n this.queueNames = queueNames;\n this.options = options;\n if (!this.options.defaultQueue) {\n this.options.defaultQueue = queueNames[0];\n }\n this.instanceStack = [];\n this._timers = [];\n this._debouncees = [];\n this._throttlers = [];\n this._eventCallbacks = {\n end: [],\n begin: []\n };\n this._onBegin = this.options.onBegin || noop;\n this._onEnd = this.options.onEnd || noop;\n var _platform = this.options._platform || {};\n var platform = Object.create(null);\n platform.setTimeout = _platform.setTimeout || function (fn, ms) {\n return setTimeout(fn, ms);\n };\n platform.clearTimeout = _platform.clearTimeout || function (id) {\n return clearTimeout(id);\n };\n platform.next = _platform.next || function (fn) {\n return SET_TIMEOUT(fn, 0);\n };\n platform.clearNext = _platform.clearNext || platform.clearTimeout;\n platform.now = _platform.now || function () {\n return Date.now();\n };\n this._platform = platform;\n this._boundRunExpiredTimers = function () {\n _this._runExpiredTimers();\n };\n this._boundAutorunEnd = function () {\n _this._autorun = null;\n _this.end();\n };\n }\n /*\n @method begin\n @return instantiated class DeferredActionQueues\n */\n\n Backburner.prototype.begin = function () {\n var options = this.options;\n var previousInstance = this.currentInstance;\n var current = void 0;\n if (this._autorun !== null) {\n current = previousInstance;\n this._cancelAutorun();\n } else {\n if (previousInstance !== null) {\n this.instanceStack.push(previousInstance);\n }\n current = this.currentInstance = new DeferredActionQueues(this.queueNames, options);\n this._trigger('begin', current, previousInstance);\n }\n this._onBegin(current, previousInstance);\n return current;\n };\n\n Backburner.prototype.end = function () {\n var currentInstance = this.currentInstance,\n next;\n var nextInstance = null;\n if (currentInstance === null) {\n throw new Error('end called without begin');\n }\n // Prevent double-finally bug in Safari 6.0.2 and iOS 6\n // This bug appears to be resolved in Safari 6.0.5 and iOS 7\n var finallyAlreadyCalled = false;\n var result = void 0;\n try {\n result = currentInstance.flush();\n } finally {\n if (!finallyAlreadyCalled) {\n finallyAlreadyCalled = true;\n if (result === 1 /* Pause */) {\n next = this._platform.next;\n\n this._autorun = next(this._boundAutorunEnd);\n } else {\n this.currentInstance = null;\n if (this.instanceStack.length > 0) {\n nextInstance = this.instanceStack.pop();\n this.currentInstance = nextInstance;\n }\n this._trigger('end', currentInstance, nextInstance);\n this._onEnd(currentInstance, nextInstance);\n }\n }\n }\n };\n\n Backburner.prototype.on = function (eventName, callback) {\n if (typeof callback !== 'function') {\n throw new TypeError('Callback must be a function');\n }\n var callbacks = this._eventCallbacks[eventName];\n if (callbacks !== undefined) {\n callbacks.push(callback);\n } else {\n throw new TypeError('Cannot on() event ' + eventName + ' because it does not exist');\n }\n };\n\n Backburner.prototype.off = function (eventName, callback) {\n var callbacks = this._eventCallbacks[eventName],\n i;\n if (!eventName || callbacks === undefined) {\n throw new TypeError('Cannot off() event ' + eventName + ' because it does not exist');\n }\n var callbackFound = false;\n if (callback) {\n for (i = 0; i < callbacks.length; i++) {\n if (callbacks[i] === callback) {\n callbackFound = true;\n callbacks.splice(i, 1);\n i--;\n }\n }\n }\n if (!callbackFound) {\n throw new TypeError('Cannot off() callback that does not exist');\n }\n };\n\n Backburner.prototype.run = function () {\n var _parseArgs = parseArgs.apply(undefined, arguments),\n target = _parseArgs[0],\n method = _parseArgs[1],\n args = _parseArgs[2];\n\n return this._run(target, method, args);\n };\n\n Backburner.prototype.join = function () {\n var _parseArgs2 = parseArgs.apply(undefined, arguments),\n target = _parseArgs2[0],\n method = _parseArgs2[1],\n args = _parseArgs2[2];\n\n return this._join(target, method, args);\n };\n\n Backburner.prototype.defer = function () {\n return this.schedule.apply(this, arguments);\n };\n\n Backburner.prototype.schedule = function (queueName) {\n for (_len = arguments.length, _args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n _args[_key - 1] = arguments[_key];\n }\n\n var _parseArgs3 = parseArgs.apply(undefined, _args),\n target = _parseArgs3[0],\n method = _parseArgs3[1],\n args = _parseArgs3[2],\n _len,\n _args,\n _key;\n\n var stack = this.DEBUG ? new Error() : undefined;\n return this._ensureInstance().schedule(queueName, target, method, args, false, stack);\n };\n\n Backburner.prototype.scheduleIterable = function (queueName, iterable) {\n var stack = this.DEBUG ? new Error() : undefined;\n return this._ensureInstance().schedule(queueName, null, iteratorDrain, [iterable], false, stack);\n };\n\n Backburner.prototype.deferOnce = function () {\n return this.scheduleOnce.apply(this, arguments);\n };\n\n Backburner.prototype.scheduleOnce = function (queueName) {\n for (_len2 = arguments.length, _args = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {\n _args[_key2 - 1] = arguments[_key2];\n }\n\n var _parseArgs4 = parseArgs.apply(undefined, _args),\n target = _parseArgs4[0],\n method = _parseArgs4[1],\n args = _parseArgs4[2],\n _len2,\n _args,\n _key2;\n\n var stack = this.DEBUG ? new Error() : undefined;\n return this._ensureInstance().schedule(queueName, target, method, args, true, stack);\n };\n\n Backburner.prototype.setTimeout = function () {\n return this.later.apply(this, arguments);\n };\n\n Backburner.prototype.later = function () {\n for (_len3 = arguments.length, args = Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {\n args[_key3] = arguments[_key3];\n }\n\n var length = args.length,\n _len3,\n args,\n _key3,\n last;\n var wait = 0;\n var method = void 0;\n var target = void 0;\n var methodOrTarget = void 0;\n var methodOrWait = void 0;\n var methodOrArgs = void 0;\n if (length === 0) {\n return;\n } else if (length === 1) {\n method = args.shift();\n } else if (length === 2) {\n methodOrTarget = args[0];\n methodOrWait = args[1];\n if (isFunction(methodOrWait)) {\n target = args.shift();\n method = args.shift();\n } else if (methodOrTarget !== null && isString(methodOrWait) && methodOrWait in methodOrTarget) {\n target = args.shift();\n method = target[args.shift()];\n } else if (isCoercableNumber(methodOrWait)) {\n method = args.shift();\n wait = parseInt(args.shift(), 10);\n } else {\n method = args.shift();\n }\n } else {\n last = args[args.length - 1];\n\n if (isCoercableNumber(last)) {\n wait = parseInt(args.pop(), 10);\n }\n methodOrTarget = args[0];\n methodOrArgs = args[1];\n if (isFunction(methodOrArgs)) {\n target = args.shift();\n method = args.shift();\n } else if (methodOrTarget !== null && isString(methodOrArgs) && methodOrArgs in methodOrTarget) {\n target = args.shift();\n method = target[args.shift()];\n } else {\n method = args.shift();\n }\n }\n var onError = getOnError(this.options);\n var executeAt = this._platform.now() + wait;\n var fn = void 0;\n if (onError) {\n fn = function () {\n try {\n method.apply(target, args);\n } catch (e) {\n onError(e);\n }\n };\n } else {\n fn = function () {\n method.apply(target, args);\n };\n }\n return this._setTimeout(fn, executeAt);\n };\n\n Backburner.prototype.throttle = function (target, method) /*, ...args, wait, [immediate] */{\n var _this2 = this,\n _len4,\n args,\n _key4;\n\n for (_len4 = arguments.length, args = Array(_len4 > 2 ? _len4 - 2 : 0), _key4 = 2; _key4 < _len4; _key4++) {\n args[_key4 - 2] = arguments[_key4];\n }\n\n var immediate = args.pop();\n var isImmediate = void 0;\n var wait = void 0;\n if (isCoercableNumber(immediate)) {\n wait = immediate;\n isImmediate = true;\n } else {\n wait = args.pop();\n isImmediate = immediate === true;\n }\n if (isString(method)) {\n method = target[method];\n }\n var index = findItem(target, method, this._throttlers);\n if (index > -1) {\n this._throttlers[index + 2] = args;\n return this._throttlers[index + 3];\n } // throttled\n wait = parseInt(wait, 10);\n var timer = this._platform.setTimeout(function () {\n var i = findTimer(timer, _this2._throttlers);\n\n var _throttlers$splice = _this2._throttlers.splice(i, 4),\n context = _throttlers$splice[0],\n func = _throttlers$splice[1],\n params = _throttlers$splice[2];\n\n if (isImmediate === false) {\n _this2._run(context, func, params);\n }\n }, wait);\n if (isImmediate) {\n this._join(target, method, args);\n }\n this._throttlers.push(target, method, args, timer);\n return timer;\n };\n\n Backburner.prototype.debounce = function (target, method) /* , wait, [immediate] */{\n var _this3 = this,\n _len5,\n args,\n _key5,\n timerId;\n\n for (_len5 = arguments.length, args = Array(_len5 > 2 ? _len5 - 2 : 0), _key5 = 2; _key5 < _len5; _key5++) {\n args[_key5 - 2] = arguments[_key5];\n }\n\n var immediate = args.pop();\n var isImmediate = void 0;\n var wait = void 0;\n if (isCoercableNumber(immediate)) {\n wait = immediate;\n isImmediate = false;\n } else {\n wait = args.pop();\n isImmediate = immediate === true;\n }\n if (isString(method)) {\n method = target[method];\n }\n wait = parseInt(wait, 10);\n // Remove debouncee\n var index = findItem(target, method, this._debouncees);\n if (index > -1) {\n timerId = this._debouncees[index + 3];\n\n this._platform.clearTimeout(timerId);\n this._debouncees.splice(index, 4);\n }\n var timer = this._platform.setTimeout(function () {\n var i = findTimer(timer, _this3._debouncees);\n\n var _debouncees$splice = _this3._debouncees.splice(i, 4),\n context = _debouncees$splice[0],\n func = _debouncees$splice[1],\n params = _debouncees$splice[2];\n\n if (isImmediate === false) {\n _this3._run(context, func, params);\n }\n }, wait);\n if (isImmediate && index === -1) {\n this._join(target, method, args);\n }\n this._debouncees.push(target, method, args, timer);\n return timer;\n };\n\n Backburner.prototype.cancelTimers = function () {\n var i, t;\n\n for (i = 3; i < this._throttlers.length; i += 4) {\n this._platform.clearTimeout(this._throttlers[i]);\n }\n this._throttlers = [];\n for (t = 3; t < this._debouncees.length; t += 4) {\n this._platform.clearTimeout(this._debouncees[t]);\n }\n this._debouncees = [];\n this._clearTimerTimeout();\n this._timers = [];\n this._cancelAutorun();\n };\n\n Backburner.prototype.hasTimers = function () {\n return this._timers.length > 0 || this._debouncees.length > 0 || this._throttlers.length > 0 || this._autorun !== null;\n };\n\n Backburner.prototype.cancel = function (timer) {\n if (!timer) {\n return false;\n }\n var timerType = typeof timer;\n if (timerType === 'number' || timerType === 'string') {\n return this._cancelItem(timer, this._throttlers) || this._cancelItem(timer, this._debouncees);\n } else if (timerType === 'function') {\n return this._cancelLaterTimer(timer);\n } else if (timerType === 'object' && timer.queue && timer.method) {\n return timer.queue.cancel(timer);\n }\n return false;\n };\n\n Backburner.prototype.ensureInstance = function () {\n this._ensureInstance();\n };\n\n Backburner.prototype._join = function (target, method, args) {\n if (this.currentInstance === null) {\n return this._run(target, method, args);\n }\n if (target === undefined && args === undefined) {\n return method();\n } else {\n return method.apply(target, args);\n }\n };\n\n Backburner.prototype._run = function (target, method, args) {\n var onError = getOnError(this.options);\n this.begin();\n if (onError) {\n try {\n return method.apply(target, args);\n } catch (error) {\n onError(error);\n } finally {\n this.end();\n }\n } else {\n try {\n return method.apply(target, args);\n } finally {\n this.end();\n }\n }\n };\n\n Backburner.prototype._cancelAutorun = function () {\n if (this._autorun !== null) {\n this._platform.clearNext(this._autorun);\n this._autorun = null;\n }\n };\n\n Backburner.prototype._setTimeout = function (fn, executeAt) {\n if (this._timers.length === 0) {\n this._timers.push(executeAt, fn);\n this._installTimerTimeout();\n return fn;\n }\n // find position to insert\n var i = binarySearch(executeAt, this._timers);\n this._timers.splice(i, 0, executeAt, fn);\n // we should be the new earliest timer if i == 0\n if (i === 0) {\n this._reinstallTimerTimeout();\n }\n return fn;\n };\n\n Backburner.prototype._cancelLaterTimer = function (timer) {\n var i;\n\n for (i = 1; i < this._timers.length; i += 2) {\n if (this._timers[i] === timer) {\n i = i - 1;\n this._timers.splice(i, 2); // remove the two elements\n if (i === 0) {\n this._reinstallTimerTimeout();\n }\n return true;\n }\n }\n return false;\n };\n\n Backburner.prototype._cancelItem = function (timer, array) {\n var index = findTimer(timer, array);\n if (index > -1) {\n this._platform.clearTimeout(timer);\n array.splice(index, 4);\n return true;\n }\n return false;\n };\n\n Backburner.prototype._trigger = function (eventName, arg1, arg2) {\n var callbacks = this._eventCallbacks[eventName],\n i;\n if (callbacks !== undefined) {\n for (i = 0; i < callbacks.length; i++) {\n callbacks[i](arg1, arg2);\n }\n }\n };\n\n Backburner.prototype._runExpiredTimers = function () {\n this._timerTimeoutId = null;\n if (this._timers.length === 0) {\n return;\n }\n this.begin();\n this._scheduleExpiredTimers();\n this.end();\n };\n\n Backburner.prototype._scheduleExpiredTimers = function () {\n var timers = this._timers,\n executeAt,\n fn;\n var l = timers.length;\n var i = 0;\n var defaultQueue = this.options.defaultQueue;\n var n = this._platform.now();\n for (; i < l; i += 2) {\n executeAt = timers[i];\n\n if (executeAt <= n) {\n fn = timers[i + 1];\n\n this.schedule(defaultQueue, null, fn);\n } else {\n break;\n }\n }\n timers.splice(0, i);\n this._installTimerTimeout();\n };\n\n Backburner.prototype._reinstallTimerTimeout = function () {\n this._clearTimerTimeout();\n this._installTimerTimeout();\n };\n\n Backburner.prototype._clearTimerTimeout = function () {\n if (this._timerTimeoutId === null) {\n return;\n }\n this._platform.clearTimeout(this._timerTimeoutId);\n this._timerTimeoutId = null;\n };\n\n Backburner.prototype._installTimerTimeout = function () {\n if (this._timers.length === 0) {\n return;\n }\n var minExpiresAt = this._timers[0];\n var n = this._platform.now();\n var wait = Math.max(0, minExpiresAt - n);\n this._timerTimeoutId = this._platform.setTimeout(this._boundRunExpiredTimers, wait);\n };\n\n Backburner.prototype._ensureInstance = function () {\n var currentInstance = this.currentInstance,\n next;\n if (currentInstance === null) {\n currentInstance = this.begin();\n next = this._platform.next;\n\n this._autorun = next(this._boundAutorunEnd);\n }\n return currentInstance;\n };\n\n return Backburner;\n }();\n\n Backburner.Queue = Queue;\n\n exports.default = Backburner;\n});","enifed('container', ['exports', 'ember-utils', 'ember-debug', 'ember/features'], function (exports, _emberUtils, _emberDebug, _features) {\n 'use strict';\n\n exports.Container = exports.privatize = exports.Registry = undefined;\n\n /* globals Proxy */\n var CONTAINER_OVERRIDE = (0, _emberUtils.symbol)('CONTAINER_OVERRIDE');\n\n /**\n A container used to instantiate and cache objects.\n \n Every `Container` must be associated with a `Registry`, which is referenced\n to determine the factory and options that should be used to instantiate\n objects.\n \n The public API for `Container` is still in flux and should not be considered\n stable.\n \n @private\n @class Container\n */\n\n var Container = function () {\n function Container(registry) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n\n this.registry = registry;\n this.owner = options.owner || null;\n this.cache = (0, _emberUtils.dictionary)(options.cache || null);\n this.factoryManagerCache = (0, _emberUtils.dictionary)(options.factoryManagerCache || null);\n this[CONTAINER_OVERRIDE] = undefined;\n this.isDestroyed = false;\n\n this.validationCache = (0, _emberUtils.dictionary)(options.validationCache || null);\n }\n\n /**\n @private\n @property registry\n @type Registry\n @since 1.11.0\n */\n\n /**\n @private\n @property cache\n @type InheritingDict\n */\n\n /**\n @private\n @property validationCache\n @type InheritingDict\n */\n\n /**\n Given a fullName return a corresponding instance.\n The default behavior is for lookup to return a singleton instance.\n The singleton is scoped to the container, allowing multiple containers\n to all have their own locally scoped singletons.\n ```javascript\n let registry = new Registry();\n let container = registry.container();\n registry.register('api:twitter', Twitter);\n let twitter = container.lookup('api:twitter');\n twitter instanceof Twitter; // => true\n // by default the container will return singletons\n let twitter2 = container.lookup('api:twitter');\n twitter2 instanceof Twitter; // => true\n twitter === twitter2; //=> true\n ```\n If singletons are not wanted, an optional flag can be provided at lookup.\n ```javascript\n let registry = new Registry();\n let container = registry.container();\n registry.register('api:twitter', Twitter);\n let twitter = container.lookup('api:twitter', { singleton: false });\n let twitter2 = container.lookup('api:twitter', { singleton: false });\n twitter === twitter2; //=> false\n ```\n @private\n @method lookup\n @param {String} fullName\n @param {Object} [options]\n @param {String} [options.source] The fullname of the request source (used for local lookup)\n @return {any}\n */\n\n Container.prototype.lookup = function (fullName, options) {\n true && !this.registry.isValidFullName(fullName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.registry.isValidFullName(fullName));\n\n return _lookup(this, this.registry.normalize(fullName), options);\n };\n\n Container.prototype.destroy = function () {\n destroyDestroyables(this);\n this.isDestroyed = true;\n };\n\n Container.prototype.reset = function (fullName) {\n if (fullName === undefined) {\n resetCache(this);\n } else {\n resetMember(this, this.registry.normalize(fullName));\n }\n };\n\n Container.prototype.ownerInjection = function () {\n var _ref;\n\n return _ref = {}, _ref[_emberUtils.OWNER] = this.owner, _ref;\n };\n\n Container.prototype._resolverCacheKey = function (name, options) {\n return this.registry.resolverCacheKey(name, options);\n };\n\n Container.prototype.factoryFor = function (fullName) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n expandedFullName;\n\n var normalizedName = this.registry.normalize(fullName);\n\n true && !this.registry.isValidFullName(normalizedName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.registry.isValidFullName(normalizedName));\n\n if (options.source) {\n expandedFullName = this.registry.expandLocalLookup(fullName, options);\n // if expandLocalLookup returns falsey, we do not support local lookup\n\n if (!_features.EMBER_MODULE_UNIFICATION) {\n if (!expandedFullName) {\n return;\n }\n\n normalizedName = expandedFullName;\n } else if (expandedFullName) {\n // with ember-module-unification, if expandLocalLookup returns something,\n // pass it to the resolve without the source\n normalizedName = expandedFullName;\n options = {};\n }\n }\n\n var cacheKey = this._resolverCacheKey(normalizedName, options);\n var cached = this.factoryManagerCache[cacheKey];\n\n if (cached !== undefined) {\n return cached;\n }\n\n var factory = _features.EMBER_MODULE_UNIFICATION ? this.registry.resolve(normalizedName, options) : this.registry.resolve(normalizedName);\n\n if (factory === undefined) {\n return;\n }\n\n if (true && factory && typeof factory._onLookup === 'function') {\n factory._onLookup(fullName);\n }\n\n var manager = new FactoryManager(this, factory, fullName, normalizedName);\n\n manager = wrapManagerInDeprecationProxy(manager);\n\n\n this.factoryManagerCache[cacheKey] = manager;\n return manager;\n };\n\n return Container;\n }();\n\n /*\n * Wrap a factory manager in a proxy which will not permit properties to be\n * set on the manager.\n */\n function wrapManagerInDeprecationProxy(manager) {\n var validator, m, proxiedManager;\n\n if (_emberUtils.HAS_NATIVE_PROXY) {\n validator = {\n set: function (obj, prop) {\n throw new Error('You attempted to set \"' + prop + '\" on a factory manager created by container#factoryFor. A factory manager is a read-only construct.');\n }\n };\n\n // Note:\n // We have to proxy access to the manager here so that private property\n // access doesn't cause the above errors to occur.\n\n m = manager;\n proxiedManager = {\n class: m.class,\n create: function (props) {\n return m.create(props);\n }\n };\n\n\n return new Proxy(proxiedManager, validator);\n }\n\n return manager;\n }\n\n function isSingleton(container, fullName) {\n return container.registry.getOption(fullName, 'singleton') !== false;\n }\n\n function isInstantiatable(container, fullName) {\n return container.registry.getOption(fullName, 'instantiate') !== false;\n }\n\n function _lookup(container, fullName) {\n var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},\n expandedFullName,\n cacheKey,\n cached;\n\n if (options.source) {\n expandedFullName = container.registry.expandLocalLookup(fullName, options);\n\n\n if (!_features.EMBER_MODULE_UNIFICATION) {\n // if expandLocalLookup returns falsey, we do not support local lookup\n if (!expandedFullName) {\n return;\n }\n\n fullName = expandedFullName;\n } else if (expandedFullName) {\n // with ember-module-unification, if expandLocalLookup returns something,\n // pass it to the resolve without the source\n fullName = expandedFullName;\n options = {};\n }\n }\n\n if (options.singleton !== false) {\n cacheKey = container._resolverCacheKey(fullName, options);\n cached = container.cache[cacheKey];\n\n if (cached !== undefined) {\n return cached;\n }\n }\n\n return instantiateFactory(container, fullName, options);\n }\n\n function isSingletonClass(container, fullName, _ref2) {\n var instantiate = _ref2.instantiate,\n singleton = _ref2.singleton;\n\n return singleton !== false && !instantiate && isSingleton(container, fullName) && !isInstantiatable(container, fullName);\n }\n\n function isSingletonInstance(container, fullName, _ref3) {\n var instantiate = _ref3.instantiate,\n singleton = _ref3.singleton;\n\n return singleton !== false && instantiate !== false && isSingleton(container, fullName) && isInstantiatable(container, fullName);\n }\n\n function isFactoryClass(container, fullname, _ref4) {\n var instantiate = _ref4.instantiate,\n singleton = _ref4.singleton;\n\n return instantiate === false && (singleton === false || !isSingleton(container, fullname)) && !isInstantiatable(container, fullname);\n }\n\n function isFactoryInstance(container, fullName, _ref5) {\n var instantiate = _ref5.instantiate,\n singleton = _ref5.singleton;\n\n return instantiate !== false && (singleton !== false || isSingleton(container, fullName)) && isInstantiatable(container, fullName);\n }\n\n function instantiateFactory(container, fullName, options) {\n var factoryManager = _features.EMBER_MODULE_UNIFICATION && options && options.source ? container.factoryFor(fullName, options) : container.factoryFor(fullName),\n cacheKey;\n\n if (factoryManager === undefined) {\n return;\n }\n\n // SomeClass { singleton: true, instantiate: true } | { singleton: true } | { instantiate: true } | {}\n // By default majority of objects fall into this case\n if (isSingletonInstance(container, fullName, options)) {\n cacheKey = container._resolverCacheKey(fullName, options);\n\n return container.cache[cacheKey] = factoryManager.create();\n }\n\n // SomeClass { singleton: false, instantiate: true }\n if (isFactoryInstance(container, fullName, options)) {\n return factoryManager.create();\n }\n\n // SomeClass { singleton: true, instantiate: false } | { instantiate: false } | { singleton: false, instantiation: false }\n if (isSingletonClass(container, fullName, options) || isFactoryClass(container, fullName, options)) {\n return factoryManager.class;\n }\n\n throw new Error('Could not create factory');\n }\n\n function buildInjections(container, injections) {\n var hash = {},\n injection,\n i;\n var isDynamic = false;\n\n if (injections.length > 0) {\n container.registry.validateInjections(injections);\n injection = void 0;\n\n for (i = 0; i < injections.length; i++) {\n injection = injections[i];\n hash[injection.property] = _lookup(container, injection.fullName);\n if (!isDynamic) {\n isDynamic = !isSingleton(container, injection.fullName);\n }\n }\n }\n\n return { injections: hash, isDynamic: isDynamic };\n }\n\n function injectionsFor(container, fullName) {\n var registry = container.registry;\n\n var _fullName$split = fullName.split(':'),\n type = _fullName$split[0];\n\n var injections = registry.getTypeInjections(type).concat(registry.getInjections(fullName));\n return buildInjections(container, injections);\n }\n\n function destroyDestroyables(container) {\n var cache = container.cache,\n i,\n key,\n value;\n var keys = Object.keys(cache);\n\n for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = cache[key];\n\n\n if (value.destroy) {\n value.destroy();\n }\n }\n }\n\n function resetCache(container) {\n destroyDestroyables(container);\n container.cache = (0, _emberUtils.dictionary)(null);\n container.factoryManagerCache = (0, _emberUtils.dictionary)(null);\n }\n\n function resetMember(container, fullName) {\n var member = container.cache[fullName];\n\n delete container.factoryManagerCache[fullName];\n\n if (member) {\n delete container.cache[fullName];\n\n if (member.destroy) {\n member.destroy();\n }\n }\n }\n\n var FactoryManager = function () {\n function FactoryManager(container, factory, fullName, normalizedName) {\n\n this.container = container;\n this.owner = container.owner;\n this.class = factory;\n this.fullName = fullName;\n this.normalizedName = normalizedName;\n this.madeToString = undefined;\n this.injections = undefined;\n }\n\n FactoryManager.prototype.toString = function () {\n if (this.madeToString === undefined) {\n this.madeToString = this.container.registry.makeToString(this.class, this.fullName);\n }\n\n return this.madeToString;\n };\n\n FactoryManager.prototype.create = function () {\n var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n _injectionsFor,\n injections,\n isDynamic;\n\n var injectionsCache = this.injections;\n if (injectionsCache === undefined) {\n _injectionsFor = injectionsFor(this.container, this.normalizedName), injections = _injectionsFor.injections, isDynamic = _injectionsFor.isDynamic;\n\n\n injectionsCache = injections;\n if (!isDynamic) {\n this.injections = injections;\n }\n }\n\n var props = (0, _emberUtils.assign)({}, injectionsCache, options);\n\n var lazyInjections = void 0;\n var validationCache = this.container.validationCache;\n // Ensure that all lazy injections are valid at instantiation time\n if (!validationCache[this.fullName] && this.class && typeof this.class._lazyInjections === 'function') {\n lazyInjections = this.class._lazyInjections();\n lazyInjections = this.container.registry.normalizeInjectionsHash(lazyInjections);\n\n this.container.registry.validateInjections(lazyInjections);\n }\n\n validationCache[this.fullName] = true;\n\n\n if (!this.class.create) {\n throw new Error('Failed to create an instance of \\'' + this.normalizedName + '\\'. Most likely an improperly defined class or' + ' an invalid module export.');\n }\n\n // required to allow access to things like\n // the customized toString, _debugContainerKey,\n // owner, etc. without a double extend and without\n // modifying the objects properties\n if (typeof this.class._initFactory === 'function') {\n this.class._initFactory(this);\n } else {\n // in the non-EmberObject case we need to still setOwner\n // this is required for supporting glimmer environment and\n // template instantiation which rely heavily on\n // `options[OWNER]` being passed into `create`\n // TODO: clean this up, and remove in future versions\n (0, _emberUtils.setOwner)(props, this.owner);\n }\n\n return this.class.create(props);\n };\n\n return FactoryManager;\n }();\n\n var VALID_FULL_NAME_REGEXP = /^[^:]+:[^:]+$/;\n\n /**\n A registry used to store factory and option information keyed\n by type.\n \n A `Registry` stores the factory and option information needed by a\n `Container` to instantiate and cache objects.\n \n The API for `Registry` is still in flux and should not be considered stable.\n \n @private\n @class Registry\n @since 1.11.0\n */\n\n var Registry = function () {\n function Registry() {\n var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n\n this.fallback = options.fallback || null;\n this.resolver = options.resolver || null;\n\n if (typeof this.resolver === 'function') {\n deprecateResolverFunction(this);\n }\n\n this.registrations = (0, _emberUtils.dictionary)(options.registrations || null);\n\n this._typeInjections = (0, _emberUtils.dictionary)(null);\n this._injections = (0, _emberUtils.dictionary)(null);\n\n this._localLookupCache = Object.create(null);\n this._normalizeCache = (0, _emberUtils.dictionary)(null);\n this._resolveCache = (0, _emberUtils.dictionary)(null);\n this._failCache = (0, _emberUtils.dictionary)(null);\n\n this._options = (0, _emberUtils.dictionary)(null);\n this._typeOptions = (0, _emberUtils.dictionary)(null);\n }\n\n /**\n A backup registry for resolving registrations when no matches can be found.\n @private\n @property fallback\n @type Registry\n */\n\n /**\n An object that has a `resolve` method that resolves a name.\n @private\n @property resolver\n @type Resolver\n */\n\n /**\n @private\n @property registrations\n @type InheritingDict\n */\n\n /**\n @private\n @property _typeInjections\n @type InheritingDict\n */\n\n /**\n @private\n @property _injections\n @type InheritingDict\n */\n\n /**\n @private\n @property _normalizeCache\n @type InheritingDict\n */\n\n /**\n @private\n @property _resolveCache\n @type InheritingDict\n */\n\n /**\n @private\n @property _options\n @type InheritingDict\n */\n\n /**\n @private\n @property _typeOptions\n @type InheritingDict\n */\n\n /**\n Creates a container based on this registry.\n @private\n @method container\n @param {Object} options\n @return {Container} created container\n */\n\n Registry.prototype.container = function (options) {\n return new Container(this, options);\n };\n\n Registry.prototype.register = function (fullName, factory) {\n var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n true && !this.isValidFullName(fullName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.isValidFullName(fullName));\n true && !(factory !== undefined) && (0, _emberDebug.assert)('Attempting to register an unknown factory: \\'' + fullName + '\\'', factory !== undefined);\n\n var normalizedName = this.normalize(fullName);\n true && !!this._resolveCache[normalizedName] && (0, _emberDebug.assert)('Cannot re-register: \\'' + fullName + '\\', as it has already been resolved.', !this._resolveCache[normalizedName]);\n\n delete this._failCache[normalizedName];\n this.registrations[normalizedName] = factory;\n this._options[normalizedName] = options;\n };\n\n Registry.prototype.unregister = function (fullName) {\n true && !this.isValidFullName(fullName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.isValidFullName(fullName));\n\n var normalizedName = this.normalize(fullName);\n\n this._localLookupCache = Object.create(null);\n\n delete this.registrations[normalizedName];\n delete this._resolveCache[normalizedName];\n delete this._failCache[normalizedName];\n delete this._options[normalizedName];\n };\n\n Registry.prototype.resolve = function (fullName, options) {\n true && !this.isValidFullName(fullName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.isValidFullName(fullName));\n\n var factory = _resolve(this, this.normalize(fullName), options),\n _fallback;\n if (factory === undefined && this.fallback !== null) {\n\n factory = (_fallback = this.fallback).resolve.apply(_fallback, arguments);\n }\n return factory;\n };\n\n Registry.prototype.describe = function (fullName) {\n if (this.resolver !== null && this.resolver.lookupDescription) {\n return this.resolver.lookupDescription(fullName);\n } else if (this.fallback !== null) {\n return this.fallback.describe(fullName);\n } else {\n return fullName;\n }\n };\n\n Registry.prototype.normalizeFullName = function (fullName) {\n if (this.resolver !== null && this.resolver.normalize) {\n return this.resolver.normalize(fullName);\n } else if (this.fallback !== null) {\n return this.fallback.normalizeFullName(fullName);\n } else {\n return fullName;\n }\n };\n\n Registry.prototype.normalize = function (fullName) {\n return this._normalizeCache[fullName] || (this._normalizeCache[fullName] = this.normalizeFullName(fullName));\n };\n\n Registry.prototype.makeToString = function (factory, fullName) {\n if (this.resolver !== null && this.resolver.makeToString) {\n return this.resolver.makeToString(factory, fullName);\n } else if (this.fallback !== null) {\n return this.fallback.makeToString(factory, fullName);\n } else {\n return factory.toString();\n }\n };\n\n Registry.prototype.has = function (fullName, options) {\n if (!this.isValidFullName(fullName)) {\n return false;\n }\n\n var source = options && options.source && this.normalize(options.source);\n\n return _has(this, this.normalize(fullName), source);\n };\n\n Registry.prototype.optionsForType = function (type, options) {\n this._typeOptions[type] = options;\n };\n\n Registry.prototype.getOptionsForType = function (type) {\n var optionsForType = this._typeOptions[type];\n if (optionsForType === undefined && this.fallback !== null) {\n optionsForType = this.fallback.getOptionsForType(type);\n }\n return optionsForType;\n };\n\n Registry.prototype.options = function (fullName) {\n var _options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n var normalizedName = this.normalize(fullName);\n this._options[normalizedName] = _options;\n };\n\n Registry.prototype.getOptions = function (fullName) {\n var normalizedName = this.normalize(fullName);\n var options = this._options[normalizedName];\n\n if (options === undefined && this.fallback !== null) {\n options = this.fallback.getOptions(fullName);\n }\n return options;\n };\n\n Registry.prototype.getOption = function (fullName, optionName) {\n var options = this._options[fullName];\n\n if (options && options[optionName] !== undefined) {\n return options[optionName];\n }\n\n var type = fullName.split(':')[0];\n options = this._typeOptions[type];\n\n if (options && options[optionName] !== undefined) {\n return options[optionName];\n } else if (this.fallback !== null) {\n return this.fallback.getOption(fullName, optionName);\n }\n };\n\n Registry.prototype.typeInjection = function (type, property, fullName) {\n true && !this.isValidFullName(fullName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.isValidFullName(fullName));\n\n var fullNameType = fullName.split(':')[0];\n true && !(fullNameType !== type) && (0, _emberDebug.assert)('Cannot inject a \\'' + fullName + '\\' on other ' + type + '(s).', fullNameType !== type);\n\n var injections = this._typeInjections[type] || (this._typeInjections[type] = []);\n\n injections.push({ property: property, fullName: fullName });\n };\n\n Registry.prototype.injection = function (fullName, property, injectionName) {\n true && !this.isValidFullName(injectionName) && (0, _emberDebug.assert)('Invalid injectionName, expected: \\'type:name\\' got: ' + injectionName, this.isValidFullName(injectionName));\n\n var normalizedInjectionName = this.normalize(injectionName);\n\n if (fullName.indexOf(':') === -1) {\n return this.typeInjection(fullName, property, normalizedInjectionName);\n }\n\n true && !this.isValidFullName(fullName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.isValidFullName(fullName));\n\n var normalizedName = this.normalize(fullName);\n\n var injections = this._injections[normalizedName] || (this._injections[normalizedName] = []);\n\n injections.push({ property: property, fullName: normalizedInjectionName });\n };\n\n Registry.prototype.knownForType = function (type) {\n var fallbackKnown = void 0,\n resolverKnown = void 0,\n index,\n fullName,\n itemType;\n\n var localKnown = (0, _emberUtils.dictionary)(null);\n var registeredNames = Object.keys(this.registrations);\n for (index = 0; index < registeredNames.length; index++) {\n fullName = registeredNames[index];\n itemType = fullName.split(':')[0];\n\n\n if (itemType === type) {\n localKnown[fullName] = true;\n }\n }\n\n if (this.fallback !== null) {\n fallbackKnown = this.fallback.knownForType(type);\n }\n\n if (this.resolver !== null && this.resolver.knownForType) {\n resolverKnown = this.resolver.knownForType(type);\n }\n\n return (0, _emberUtils.assign)({}, fallbackKnown, localKnown, resolverKnown);\n };\n\n Registry.prototype.isValidFullName = function (fullName) {\n return VALID_FULL_NAME_REGEXP.test(fullName);\n };\n\n Registry.prototype.getInjections = function (fullName) {\n var injections = this._injections[fullName] || [];\n if (this.fallback !== null) {\n injections = injections.concat(this.fallback.getInjections(fullName));\n }\n return injections;\n };\n\n Registry.prototype.getTypeInjections = function (type) {\n var injections = this._typeInjections[type] || [];\n if (this.fallback !== null) {\n injections = injections.concat(this.fallback.getTypeInjections(type));\n }\n return injections;\n };\n\n Registry.prototype.resolverCacheKey = function (name, options) {\n if (!_features.EMBER_MODULE_UNIFICATION) {\n return name;\n }\n\n return options && options.source ? options.source + ':' + name : name;\n };\n\n Registry.prototype.expandLocalLookup = function (fullName, options) {\n var normalizedFullName, normalizedSource;\n\n if (this.resolver !== null && this.resolver.expandLocalLookup) {\n true && !this.isValidFullName(fullName) && (0, _emberDebug.assert)('fullName must be a proper full name', this.isValidFullName(fullName));\n true && !(options && options.source) && (0, _emberDebug.assert)('options.source must be provided to expandLocalLookup', options && options.source);\n true && !this.isValidFullName(options.source) && (0, _emberDebug.assert)('options.source must be a proper full name', this.isValidFullName(options.source));\n\n normalizedFullName = this.normalize(fullName);\n normalizedSource = this.normalize(options.source);\n\n\n return _expandLocalLookup(this, normalizedFullName, normalizedSource);\n } else if (this.fallback !== null) {\n return this.fallback.expandLocalLookup(fullName, options);\n } else {\n return null;\n }\n };\n\n return Registry;\n }();\n\n function deprecateResolverFunction(registry) {\n true && !false && (0, _emberDebug.deprecate)('Passing a `resolver` function into a Registry is deprecated. Please pass in a Resolver object with a `resolve` method.', false, { id: 'ember-application.registry-resolver-as-function', until: '3.0.0', url: 'https://emberjs.com/deprecations/v2.x#toc_registry-resolver-as-function' });\n\n registry.resolver = { resolve: registry.resolver };\n }\n\n Registry.prototype.normalizeInjectionsHash = function (hash) {\n var injections = [];\n\n for (var key in hash) {\n if (hash.hasOwnProperty(key)) {\n true && !this.isValidFullName(hash[key]) && (0, _emberDebug.assert)('Expected a proper full name, given \\'' + hash[key] + '\\'', this.isValidFullName(hash[key]));\n\n injections.push({\n property: key,\n fullName: hash[key]\n });\n }\n }\n\n return injections;\n };\n\n Registry.prototype.validateInjections = function (injections) {\n if (!injections) {\n return;\n }\n\n var fullName = void 0,\n i;\n\n for (i = 0; i < injections.length; i++) {\n fullName = injections[i].fullName;\n\n true && !this.has(fullName) && (0, _emberDebug.assert)('Attempting to inject an unknown injection: \\'' + fullName + '\\'', this.has(fullName));\n }\n };\n\n\n function _expandLocalLookup(registry, normalizedName, normalizedSource) {\n var cache = registry._localLookupCache;\n var normalizedNameCache = cache[normalizedName];\n\n if (!normalizedNameCache) {\n normalizedNameCache = cache[normalizedName] = Object.create(null);\n }\n\n var cached = normalizedNameCache[normalizedSource];\n\n if (cached !== undefined) {\n return cached;\n }\n\n var expanded = registry.resolver.expandLocalLookup(normalizedName, normalizedSource);\n\n return normalizedNameCache[normalizedSource] = expanded;\n }\n\n function _resolve(registry, normalizedName, options) {\n if (options && options.source) {\n // when `source` is provided expand normalizedName\n // and source into the full normalizedName\n expandedNormalizedName = registry.expandLocalLookup(normalizedName, options);\n\n // if expandLocalLookup returns falsey, we do not support local lookup\n\n if (!_features.EMBER_MODULE_UNIFICATION) {\n if (!expandedNormalizedName) {\n return;\n }\n\n normalizedName = expandedNormalizedName;\n } else if (expandedNormalizedName) {\n // with ember-module-unification, if expandLocalLookup returns something,\n // pass it to the resolve without the source\n normalizedName = expandedNormalizedName;\n options = {};\n }\n }\n\n var cacheKey = registry.resolverCacheKey(normalizedName, options),\n expandedNormalizedName;\n var cached = registry._resolveCache[cacheKey];\n if (cached !== undefined) {\n return cached;\n }\n if (registry._failCache[cacheKey]) {\n return;\n }\n\n var resolved = void 0;\n\n if (registry.resolver) {\n resolved = registry.resolver.resolve(normalizedName, options && options.source);\n }\n\n if (resolved === undefined) {\n resolved = registry.registrations[normalizedName];\n }\n\n if (resolved === undefined) {\n registry._failCache[cacheKey] = true;\n } else {\n registry._resolveCache[cacheKey] = resolved;\n }\n\n return resolved;\n }\n\n function _has(registry, fullName, source) {\n return registry.resolve(fullName, { source: source }) !== undefined;\n }\n\n var privateNames = (0, _emberUtils.dictionary)(null);\n var privateSuffix = ('' + Math.random() + Date.now()).replace('.', '');\n\n /*\n Public API for the container is still in flux.\n The public API, specified on the application namespace should be considered the stable API.\n // @module container\n @private\n */\n\n exports.Registry = Registry;\n exports.privatize = function (_ref6) {\n var fullName = _ref6[0];\n\n var name = privateNames[fullName];\n if (name) {\n return name;\n }\n\n var _fullName$split2 = fullName.split(':'),\n type = _fullName$split2[0],\n rawName = _fullName$split2[1];\n\n return privateNames[fullName] = (0, _emberUtils.intern)(type + ':' + rawName + '-' + privateSuffix);\n };\n exports.Container = Container;\n});","enifed('ember-babel', ['exports'], function (exports) {\n 'use strict';\n\n exports.inherits = function (subClass, superClass) {\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n\n if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : defaults(subClass, superClass);\n };\n exports.taggedTemplateLiteralLoose = function (strings, raw) {\n strings.raw = raw;\n return strings;\n };\n exports.createClass = function (Constructor, protoProps, staticProps) {\n if (protoProps) defineProperties(Constructor.prototype, protoProps);\n if (staticProps) defineProperties(Constructor, staticProps);\n return Constructor;\n };\n exports.defaults = defaults;\n\n\n function defineProperties(target, props) {\n var i, descriptor;\n\n for (i = 0; i < props.length; i++) {\n descriptor = props[i];\n\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if ('value' in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n\n function defaults(obj, defaults) {\n var keys = Object.getOwnPropertyNames(defaults),\n i,\n key,\n value;\n for (i = 0; i < keys.length; i++) {\n key = keys[i];\n value = Object.getOwnPropertyDescriptor(defaults, key);\n\n if (value && value.configurable && obj[key] === undefined) {\n Object.defineProperty(obj, key, value);\n }\n }\n return obj;\n }\n\n exports.possibleConstructorReturn = function (self, call) {\n return call && (typeof call === 'object' || typeof call === 'function') ? call : self;\n };\n\n exports.slice = Array.prototype.slice;\n});","enifed('ember-console', ['exports', 'ember-environment'], function (exports, _emberEnvironment) {\n 'use strict';\n\n function K() {}\n\n function consoleMethod(name) {\n var consoleObj = void 0;\n if (_emberEnvironment.context.imports.console) {\n consoleObj = _emberEnvironment.context.imports.console;\n } else if (typeof console !== 'undefined') {\n // eslint-disable-line no-undef\n consoleObj = console; // eslint-disable-line no-undef\n }\n\n var method = typeof consoleObj === 'object' ? consoleObj[name] : null;\n\n if (typeof method !== 'function') {\n return;\n }\n\n return method.bind(consoleObj);\n }\n\n /**\n Inside Ember-Metal, simply uses the methods from `imports.console`.\n Override this to provide more robust logging functionality.\n \n @class Logger\n @namespace Ember\n @public\n */\n var index = {\n /**\n Logs the arguments to the console.\n You can pass as many arguments as you want and they will be joined together with a space.\n ```javascript\n var foo = 1;\n Ember.Logger.log('log value of foo:', foo);\n // \"log value of foo: 1\" will be printed to the console\n ```\n @method log\n @for Ember.Logger\n @param {*} arguments\n @public\n */\n log: consoleMethod('log') || K,\n\n /**\n Prints the arguments to the console with a warning icon.\n You can pass as many arguments as you want and they will be joined together with a space.\n ```javascript\n Ember.Logger.warn('Something happened!');\n // \"Something happened!\" will be printed to the console with a warning icon.\n ```\n @method warn\n @for Ember.Logger\n @param {*} arguments\n @public\n */\n warn: consoleMethod('warn') || K,\n\n /**\n Prints the arguments to the console with an error icon, red text and a stack trace.\n You can pass as many arguments as you want and they will be joined together with a space.\n ```javascript\n Ember.Logger.error('Danger! Danger!');\n // \"Danger! Danger!\" will be printed to the console in red text.\n ```\n @method error\n @for Ember.Logger\n @param {*} arguments\n @public\n */\n error: consoleMethod('error') || K,\n\n /**\n Logs the arguments to the console.\n You can pass as many arguments as you want and they will be joined together with a space.\n ```javascript\n var foo = 1;\n Ember.Logger.info('log value of foo:', foo);\n // \"log value of foo: 1\" will be printed to the console\n ```\n @method info\n @for Ember.Logger\n @param {*} arguments\n @public\n */\n info: consoleMethod('info') || K,\n\n /**\n Logs the arguments to the console in blue text.\n You can pass as many arguments as you want and they will be joined together with a space.\n ```javascript\n var foo = 1;\n Ember.Logger.debug('log value of foo:', foo);\n // \"log value of foo: 1\" will be printed to the console\n ```\n @method debug\n @for Ember.Logger\n @param {*} arguments\n @public\n */\n debug: consoleMethod('debug') || consoleMethod('info') || K,\n\n /**\n If the value passed into `Ember.Logger.assert` is not truthy it will throw an error with a stack trace.\n ```javascript\n Ember.Logger.assert(true); // undefined\n Ember.Logger.assert(true === false); // Throws an Assertion failed error.\n Ember.Logger.assert(true === false, 'Something invalid'); // Throws an Assertion failed error with message.\n ```\n @method assert\n @for Ember.Logger\n @param {Boolean} bool Value to test\n @param {String} message Assertion message on failed\n @public\n */\n assert: consoleMethod('assert') || function (test, message) {\n if (!test) {\n try {\n // attempt to preserve the stack\n throw new Error('assertion failed: ' + message);\n } catch (error) {\n setTimeout(function () {\n throw error;\n }, 0);\n }\n }\n }\n };\n\n exports.default = index;\n});","enifed('ember-debug/deprecate', ['exports', 'ember-debug/error', 'ember-console', 'ember-environment', 'ember-debug/handlers'], function (exports, _error, _emberConsole, _emberEnvironment, _handlers) {\n 'use strict';\n\n exports.missingOptionsUntilDeprecation = exports.missingOptionsIdDeprecation = exports.missingOptionsDeprecation = exports.registerHandler = undefined;\n\n /**\n @module @ember/debug\n @public\n */\n /**\n Allows for runtime registration of handler functions that override the default deprecation behavior.\n Deprecations are invoked by calls to [Ember.deprecate](https://emberjs.com/api/classes/Ember.html#method_deprecate).\n The following example demonstrates its usage by registering a handler that throws an error if the\n message contains the word \"should\", otherwise defers to the default handler.\n \n ```javascript\n Ember.Debug.registerDeprecationHandler((message, options, next) => {\n if (message.indexOf('should') !== -1) {\n throw new Error(`Deprecation message with should: ${message}`);\n } else {\n // defer to whatever handler was registered before this one\n next(message, options);\n }\n });\n ```\n \n The handler function takes the following arguments:\n \n \n \n @public\n @static\n @method registerDeprecationHandler\n @for @ember/debug\n @param handler {Function} A function to handle deprecation calls.\n @since 2.1.0\n */\n var registerHandler = function () {}; /*global __fail__*/\n\n var missingOptionsDeprecation = void 0,\n missingOptionsIdDeprecation = void 0,\n missingOptionsUntilDeprecation = void 0,\n deprecate = void 0;\n\n exports.registerHandler = registerHandler = function (handler) {\n (0, _handlers.registerHandler)('deprecate', handler);\n };\n\n var formatMessage = function (_message, options) {\n var message = _message;\n\n if (options && options.id) {\n message = message + (' [deprecation id: ' + options.id + ']');\n }\n\n if (options && options.url) {\n message += ' See ' + options.url + ' for more details.';\n }\n\n return message;\n };\n\n registerHandler(function (message, options) {\n var updatedMessage = formatMessage(message, options);\n\n _emberConsole.default.warn('DEPRECATION: ' + updatedMessage);\n });\n\n var captureErrorForStack = void 0;\n\n if (new Error().stack) {\n captureErrorForStack = function () {\n return new Error();\n };\n } else {\n captureErrorForStack = function () {\n try {\n __fail__.fail();\n } catch (e) {\n return e;\n }\n };\n }\n\n registerHandler(function (message, options, next) {\n var stackStr, error, stack, updatedMessage;\n\n if (_emberEnvironment.ENV.LOG_STACKTRACE_ON_DEPRECATION) {\n stackStr = '';\n error = captureErrorForStack();\n stack = void 0;\n\n\n if (error.stack) {\n if (error['arguments']) {\n // Chrome\n stack = error.stack.replace(/^\\s+at\\s+/gm, '').replace(/^([^\\(]+?)([\\n$])/gm, '{anonymous}($1)$2').replace(/^Object.\\s*\\(([^\\)]+)\\)/gm, '{anonymous}($1)').split('\\n');\n stack.shift();\n } else {\n // Firefox\n stack = error.stack.replace(/(?:\\n@:0)?\\s+$/m, '').replace(/^\\(/gm, '{anonymous}(').split('\\n');\n }\n\n stackStr = '\\n ' + stack.slice(2).join('\\n ');\n }\n\n updatedMessage = formatMessage(message, options);\n\n\n _emberConsole.default.warn('DEPRECATION: ' + updatedMessage + stackStr);\n } else {\n next.apply(undefined, arguments);\n }\n });\n\n registerHandler(function (message, options, next) {\n var updatedMessage;\n\n if (_emberEnvironment.ENV.RAISE_ON_DEPRECATION) {\n updatedMessage = formatMessage(message);\n\n\n throw new _error.default(updatedMessage);\n } else {\n next.apply(undefined, arguments);\n }\n });\n\n exports.missingOptionsDeprecation = missingOptionsDeprecation = 'When calling `Ember.deprecate` you ' + 'must provide an `options` hash as the third parameter. ' + '`options` should include `id` and `until` properties.';\n exports.missingOptionsIdDeprecation = missingOptionsIdDeprecation = 'When calling `Ember.deprecate` you must provide `id` in options.';\n exports.missingOptionsUntilDeprecation = missingOptionsUntilDeprecation = 'When calling `Ember.deprecate` you must provide `until` in options.';\n /**\n @module @ember/application\n @public\n */\n /**\n Display a deprecation warning with the provided message and a stack trace\n (Chrome and Firefox only).\n * In a production build, this method is defined as an empty function (NOP).\n Uses of this method in Ember itself are stripped from the ember.prod.js build.\n @method deprecate\n @for @ember/application/deprecations\n @param {String} message A description of the deprecation.\n @param {Boolean} test A boolean. If falsy, the deprecation will be displayed.\n @param {Object} options\n @param {String} options.id A unique id for this deprecation. The id can be\n used by Ember debugging tools to change the behavior (raise, log or silence)\n for that specific deprecation. The id should be namespaced by dots, e.g.\n \"view.helper.select\".\n @param {string} options.until The version of Ember when this deprecation\n warning will be removed.\n @param {String} [options.url] An optional url to the transition guide on the\n emberjs.com website.\n @static\n @public\n @since 1.0.0\n */\n deprecate = function deprecate(message, test, options) {\n if (!options || !options.id && !options.until) {\n deprecate(missingOptionsDeprecation, false, {\n id: 'ember-debug.deprecate-options-missing',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x/#toc_ember-debug-function-options'\n });\n }\n\n if (options && !options.id) {\n deprecate(missingOptionsIdDeprecation, false, {\n id: 'ember-debug.deprecate-id-missing',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x/#toc_ember-debug-function-options'\n });\n }\n\n if (options && !options.until) {\n deprecate(missingOptionsUntilDeprecation, options && options.until, {\n id: 'ember-debug.deprecate-until-missing',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x/#toc_ember-debug-function-options'\n });\n }\n\n _handlers.invoke.apply(undefined, ['deprecate'].concat(Array.prototype.slice.call(arguments)));\n };\n\n\n exports.default = deprecate;\n exports.registerHandler = registerHandler;\n exports.missingOptionsDeprecation = missingOptionsDeprecation;\n exports.missingOptionsIdDeprecation = missingOptionsIdDeprecation;\n exports.missingOptionsUntilDeprecation = missingOptionsUntilDeprecation;\n});","enifed(\"ember-debug/error\", [\"exports\", \"ember-babel\"], function (exports, _emberBabel) {\n \"use strict\";\n\n /**\n @module @ember/error\n */\n\n /**\n A subclass of the JavaScript Error object for use in Ember.\n \n @class EmberError\n @extends Error\n @constructor\n @public\n */\n\n var EmberError = function (_ExtendBuiltin) {\n (0, _emberBabel.inherits)(EmberError, _ExtendBuiltin);\n\n function EmberError(message) {\n\n var _this = (0, _emberBabel.possibleConstructorReturn)(this, _ExtendBuiltin.call(this)),\n _ret;\n\n if (!(_this instanceof EmberError)) {\n\n return _ret = new EmberError(message), (0, _emberBabel.possibleConstructorReturn)(_this, _ret);\n }\n\n var error = Error.call(_this, message);\n _this.stack = error.stack;\n _this.description = error.description;\n _this.fileName = error.fileName;\n _this.lineNumber = error.lineNumber;\n _this.message = error.message;\n _this.name = error.name;\n _this.number = error.number;\n _this.code = error.code;\n return _this;\n }\n\n return EmberError;\n }(function (klass) {\n function ExtendableBuiltin() {\n klass.apply(this, arguments);\n }\n\n ExtendableBuiltin.prototype = Object.create(klass.prototype);\n ExtendableBuiltin.prototype.constructor = ExtendableBuiltin;\n return ExtendableBuiltin;\n }(Error));\n\n exports.default = EmberError;\n});","enifed('ember-debug/features', ['exports', 'ember-environment', 'ember/features'], function (exports, _emberEnvironment, _features) {\n 'use strict';\n\n exports.default =\n\n /**\n @module ember\n */\n\n /**\n The hash of enabled Canary features. Add to this, any canary features\n before creating your application.\n \n Alternatively (and recommended), you can also define `EmberENV.FEATURES`\n if you need to enable features flagged at runtime.\n \n @class FEATURES\n @namespace Ember\n @static\n @since 1.1.0\n @public\n */\n\n // Auto-generated\n\n /**\n Determine whether the specified `feature` is enabled. Used by Ember's\n build tools to exclude experimental features from beta/stable builds.\n \n You can define the following configuration options:\n \n * `EmberENV.ENABLE_OPTIONAL_FEATURES` - enable any features that have not been explicitly\n enabled/disabled.\n \n @method isEnabled\n @param {String} feature The feature to check\n @return {Boolean}\n @for Ember.FEATURES\n @since 1.1.0\n @public\n */\n function (feature) {\n var featureValue = FEATURES[feature];\n\n if (featureValue === true || featureValue === false || featureValue === undefined) {\n return featureValue;\n } else if (_emberEnvironment.ENV.ENABLE_OPTIONAL_FEATURES) {\n return true;\n } else {\n return false;\n }\n };\n var FEATURES = _features.FEATURES;\n});","enifed('ember-debug/handlers', ['exports'], function (exports) {\n 'use strict';\n\n var HANDLERS = exports.HANDLERS = {};\n\n var registerHandler = function () {};\n var invoke = function () {};\n\n exports.registerHandler = registerHandler = function (type, callback) {\n var nextHandler = HANDLERS[type] || function () {};\n\n HANDLERS[type] = function (message, options) {\n callback(message, options, nextHandler);\n };\n };\n\n exports.invoke = invoke = function (type, message, test, options) {\n if (test) {\n return;\n }\n\n var handlerForType = HANDLERS[type];\n\n if (handlerForType) {\n handlerForType(message, options);\n }\n };\n\n\n exports.registerHandler = registerHandler;\n exports.invoke = invoke;\n});","enifed('ember-debug/index', ['exports', 'ember-debug/warn', 'ember-debug/deprecate', 'ember-debug/features', 'ember-debug/error', 'ember-debug/testing', 'ember-environment', 'ember-console', 'ember/features'], function (exports, _warn2, _deprecate2, _features, _error, _testing, _emberEnvironment, _emberConsole, _features2) {\n 'use strict';\n\n exports._warnIfUsingStrippedFeatureFlags = exports.getDebugFunction = exports.setDebugFunction = exports.deprecateFunc = exports.runInDebug = exports.debugFreeze = exports.debugSeal = exports.deprecate = exports.debug = exports.warn = exports.info = exports.assert = exports.setTesting = exports.isTesting = exports.Error = exports.isFeatureEnabled = exports.registerDeprecationHandler = exports.registerWarnHandler = undefined;\n Object.defineProperty(exports, 'registerWarnHandler', {\n enumerable: true,\n get: function () {\n return _warn2.registerHandler;\n }\n });\n Object.defineProperty(exports, 'registerDeprecationHandler', {\n enumerable: true,\n get: function () {\n return _deprecate2.registerHandler;\n }\n });\n Object.defineProperty(exports, 'isFeatureEnabled', {\n enumerable: true,\n get: function () {\n return _features.default;\n }\n });\n Object.defineProperty(exports, 'Error', {\n enumerable: true,\n get: function () {\n return _error.default;\n }\n });\n Object.defineProperty(exports, 'isTesting', {\n enumerable: true,\n get: function () {\n return _testing.isTesting;\n }\n });\n Object.defineProperty(exports, 'setTesting', {\n enumerable: true,\n get: function () {\n return _testing.setTesting;\n }\n });\n var DEFAULT_FEATURES = _features2.DEFAULT_FEATURES,\n FEATURES = _features2.FEATURES,\n featuresWereStripped,\n isFirefox,\n isChrome;\n\n // These are the default production build versions:\n var noop = function () {};\n\n var assert = noop;\n var info = noop;\n var warn = noop;\n var debug = noop;\n var deprecate = noop;\n var debugSeal = noop;\n var debugFreeze = noop;\n var runInDebug = noop;\n var setDebugFunction = noop;\n var getDebugFunction = noop;\n\n var deprecateFunc = function () {\n return arguments[arguments.length - 1];\n };\n\n exports.setDebugFunction = setDebugFunction = function (type, callback) {\n switch (type) {\n case 'assert':\n return exports.assert = assert = callback;\n case 'info':\n return exports.info = info = callback;\n case 'warn':\n return exports.warn = warn = callback;\n case 'debug':\n return exports.debug = debug = callback;\n case 'deprecate':\n return exports.deprecate = deprecate = callback;\n case 'debugSeal':\n return exports.debugSeal = debugSeal = callback;\n case 'debugFreeze':\n return exports.debugFreeze = debugFreeze = callback;\n case 'runInDebug':\n return exports.runInDebug = runInDebug = callback;\n case 'deprecateFunc':\n return exports.deprecateFunc = deprecateFunc = callback;\n }\n };\n\n exports.getDebugFunction = getDebugFunction = function (type) {\n switch (type) {\n case 'assert':\n return assert;\n case 'info':\n return info;\n case 'warn':\n return warn;\n case 'debug':\n return debug;\n case 'deprecate':\n return deprecate;\n case 'debugSeal':\n return debugSeal;\n case 'debugFreeze':\n return debugFreeze;\n case 'runInDebug':\n return runInDebug;\n case 'deprecateFunc':\n return deprecateFunc;\n }\n };\n\n /**\n @module @ember/debug\n */\n\n /**\n Define an assertion that will throw an exception if the condition is not met.\n * In a production build, this method is defined as an empty function (NOP).\n Uses of this method in Ember itself are stripped from the ember.prod.js build.\n ```javascript\n import { assert } from '@ember/debug';\n // Test for truthiness\n assert('Must pass a valid object', obj);\n // Fail unconditionally\n assert('This code path should never be run');\n ```\n @method assert\n @static\n @for @ember/debug\n @param {String} desc A description of the assertion. This will become\n the text of the Error thrown if the assertion fails.\n @param {Boolean} test Must be truthy for the assertion to pass. If\n falsy, an exception will be thrown.\n @public\n @since 1.0.0\n */\n setDebugFunction('assert', function (desc, test) {\n if (!test) {\n throw new _error.default('Assertion Failed: ' + desc);\n }\n });\n\n /**\n Display a debug notice.\n * In a production build, this method is defined as an empty function (NOP).\n Uses of this method in Ember itself are stripped from the ember.prod.js build.\n ```javascript\n import { debug } from '@ember/debug';\n debug('I\\'m a debug notice!');\n ```\n @method debug\n @for @ember/debug\n @static\n @param {String} message A debug message to display.\n @public\n */\n setDebugFunction('debug', function (message) {\n _emberConsole.default.debug('DEBUG: ' + message);\n });\n\n /**\n Display an info notice.\n * In a production build, this method is defined as an empty function (NOP).\n Uses of this method in Ember itself are stripped from the ember.prod.js build.\n @method info\n @private\n */\n setDebugFunction('info', function () {\n _emberConsole.default.info.apply(undefined, arguments);\n });\n\n /**\n @module @ember/application\n @public\n */\n\n /**\n Alias an old, deprecated method with its new counterpart.\n Display a deprecation warning with the provided message and a stack trace\n (Chrome and Firefox only) when the assigned method is called.\n * In a production build, this method is defined as an empty function (NOP).\n ```javascript\n Ember.oldMethod = Ember.deprecateFunc('Please use the new, updated method', Ember.newMethod);\n ```\n @method deprecateFunc\n @static\n @for @ember/application/deprecations\n @param {String} message A description of the deprecation.\n @param {Object} [options] The options object for Ember.deprecate.\n @param {Function} func The new function called to replace its deprecated counterpart.\n @return {Function} A new function that wraps the original function with a deprecation warning\n @private\n */\n setDebugFunction('deprecateFunc', function () {\n var _len, args, _key, message, options, func, _message, _func;\n\n for (_len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n if (args.length === 3) {\n message = args[0], options = args[1], func = args[2];\n\n\n return function () {\n deprecate(message, false, options);\n return func.apply(this, arguments);\n };\n } else {\n _message = args[0], _func = args[1];\n\n\n return function () {\n deprecate(_message);\n return _func.apply(this, arguments);\n };\n }\n });\n\n /**\n @module @ember/debug\n @public\n */\n /**\n Run a function meant for debugging.\n * In a production build, this method is defined as an empty function (NOP).\n Uses of this method in Ember itself are stripped from the ember.prod.js build.\n ```javascript\n import Component from '@ember/component';\n import { runInDebug } from '@ember/debug';\n runInDebug(() => {\n Component.reopen({\n didInsertElement() {\n console.log(\"I'm happy\");\n }\n });\n });\n ```\n @method runInDebug\n @for @ember/debug\n @static\n @param {Function} func The function to be executed.\n @since 1.5.0\n @public\n */\n setDebugFunction('runInDebug', function (func) {\n func();\n });\n\n setDebugFunction('debugSeal', function (obj) {\n Object.seal(obj);\n });\n\n setDebugFunction('debugFreeze', function (obj) {\n Object.freeze(obj);\n });\n\n setDebugFunction('deprecate', _deprecate2.default);\n\n setDebugFunction('warn', _warn2.default);\n\n\n var _warnIfUsingStrippedFeatureFlags = void 0;\n\n if (true && !(0, _testing.isTesting)()) {\n /**\n Will call `warn()` if ENABLE_OPTIONAL_FEATURES or\n any specific FEATURES flag is truthy.\n This method is called automatically in debug canary builds.\n @private\n @method _warnIfUsingStrippedFeatureFlags\n @return {void}\n */\n exports._warnIfUsingStrippedFeatureFlags = _warnIfUsingStrippedFeatureFlags = function (FEATURES, knownFeatures, featuresWereStripped) {\n var keys, i, key;\n\n if (featuresWereStripped) {\n warn('Ember.ENV.ENABLE_OPTIONAL_FEATURES is only available in canary builds.', !_emberEnvironment.ENV.ENABLE_OPTIONAL_FEATURES, { id: 'ember-debug.feature-flag-with-features-stripped' });\n\n keys = Object.keys(FEATURES || {});\n\n for (i = 0; i < keys.length; i++) {\n key = keys[i];\n\n if (key === 'isEnabled' || !(key in knownFeatures)) {\n continue;\n }\n\n warn('FEATURE[\"' + key + '\"] is set as enabled, but FEATURE flags are only available in canary builds.', !FEATURES[key], { id: 'ember-debug.feature-flag-with-features-stripped' });\n }\n }\n };\n\n // Complain if they're using FEATURE flags in builds other than canary\n FEATURES['features-stripped-test'] = true;\n featuresWereStripped = true;\n\n\n if ((0, _features.default)('features-stripped-test')) {\n featuresWereStripped = false;\n }\n\n delete FEATURES['features-stripped-test'];\n _warnIfUsingStrippedFeatureFlags(_emberEnvironment.ENV.FEATURES, DEFAULT_FEATURES, featuresWereStripped);\n\n // Inform the developer about the Ember Inspector if not installed.\n isFirefox = _emberEnvironment.environment.isFirefox;\n isChrome = _emberEnvironment.environment.isChrome;\n\n\n if (typeof window !== 'undefined' && (isFirefox || isChrome) && window.addEventListener) {\n window.addEventListener('load', function () {\n var downloadURL;\n\n if (document.documentElement && document.documentElement.dataset && !document.documentElement.dataset.emberExtension) {\n downloadURL = void 0;\n\n\n if (isChrome) {\n downloadURL = 'https://chrome.google.com/webstore/detail/ember-inspector/bmdblncegkenkacieihfhpjfppoconhi';\n } else if (isFirefox) {\n downloadURL = 'https://addons.mozilla.org/en-US/firefox/addon/ember-inspector/';\n }\n\n debug('For more advanced debugging, install the Ember Inspector from ' + downloadURL);\n }\n }, false);\n }\n }\n\n exports.assert = assert;\n exports.info = info;\n exports.warn = warn;\n exports.debug = debug;\n exports.deprecate = deprecate;\n exports.debugSeal = debugSeal;\n exports.debugFreeze = debugFreeze;\n exports.runInDebug = runInDebug;\n exports.deprecateFunc = deprecateFunc;\n exports.setDebugFunction = setDebugFunction;\n exports.getDebugFunction = getDebugFunction;\n exports._warnIfUsingStrippedFeatureFlags = _warnIfUsingStrippedFeatureFlags;\n});","enifed(\"ember-debug/testing\", [\"exports\"], function (exports) {\n \"use strict\";\n\n exports.isTesting = function () {\n return testing;\n };\n exports.setTesting = function (value) {\n testing = !!value;\n };\n var testing = false;\n});","enifed('ember-debug/warn', ['exports', 'ember-console', 'ember-debug/deprecate', 'ember-debug/handlers'], function (exports, _emberConsole, _deprecate, _handlers) {\n 'use strict';\n\n exports.missingOptionsDeprecation = exports.missingOptionsIdDeprecation = exports.registerHandler = undefined;\n\n var registerHandler = function () {};\n var warn = function () {};\n var missingOptionsDeprecation = void 0,\n missingOptionsIdDeprecation = void 0;\n\n /**\n @module @ember/debug\n */\n\n /**\n Allows for runtime registration of handler functions that override the default warning behavior.\n Warnings are invoked by calls made to [warn](https://emberjs.com/api/classes/Ember.html#method_warn).\n The following example demonstrates its usage by registering a handler that does nothing overriding Ember's\n default warning behavior.\n ```javascript\n import { registerWarnHandler } from '@ember/debug';\n // next is not called, so no warnings get the default behavior\n registerWarnHandler(() => {});\n ```\n The handler function takes the following arguments:\n \n @public\n @static\n @method registerWarnHandler\n @for @ember/debug\n @param handler {Function} A function to handle warnings.\n @since 2.1.0\n */\n exports.registerHandler = registerHandler = function (handler) {\n (0, _handlers.registerHandler)('warn', handler);\n };\n\n registerHandler(function (message) {\n _emberConsole.default.warn('WARNING: ' + message);\n if ('trace' in _emberConsole.default) {\n _emberConsole.default.trace();\n }\n });\n\n exports.missingOptionsDeprecation = missingOptionsDeprecation = 'When calling `warn` you ' + 'must provide an `options` hash as the third parameter. ' + '`options` should include an `id` property.';\n exports.missingOptionsIdDeprecation = missingOptionsIdDeprecation = 'When calling `warn` you must provide `id` in options.';\n\n /**\n Display a warning with the provided message.\n * In a production build, this method is defined as an empty function (NOP).\n Uses of this method in Ember itself are stripped from the ember.prod.js build.\n @method warn\n @for @ember/debug\n @static\n @param {String} message A warning to display.\n @param {Boolean} test An optional boolean. If falsy, the warning\n will be displayed.\n @param {Object} options An object that can be used to pass a unique\n `id` for this warning. The `id` can be used by Ember debugging tools\n to change the behavior (raise, log, or silence) for that specific warning.\n The `id` should be namespaced by dots, e.g. \"ember-debug.feature-flag-with-features-stripped\"\n @public\n @since 1.0.0\n */\n warn = function (message, test, options) {\n if (arguments.length === 2 && typeof test === 'object') {\n options = test;\n test = false;\n }\n if (!options) {\n (0, _deprecate.default)(missingOptionsDeprecation, false, {\n id: 'ember-debug.warn-options-missing',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x/#toc_ember-debug-function-options'\n });\n }\n\n if (options && !options.id) {\n (0, _deprecate.default)(missingOptionsIdDeprecation, false, {\n id: 'ember-debug.warn-id-missing',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x/#toc_ember-debug-function-options'\n });\n }\n\n (0, _handlers.invoke)('warn', message, test, options);\n };\n\n\n exports.default = warn;\n exports.registerHandler = registerHandler;\n exports.missingOptionsIdDeprecation = missingOptionsIdDeprecation;\n exports.missingOptionsDeprecation = missingOptionsDeprecation;\n});","enifed('ember-environment', ['exports'], function (exports) {\n 'use strict';\n\n /* globals global, window, self, mainContext */\n\n // from lodash to catch fake globals\n\n function checkGlobal(value) {\n return value && value.Object === Object ? value : undefined;\n }\n\n // element ids can ruin global miss checks\n\n\n // export real global\n var global$1 = checkGlobal(function (value) {\n return value && value.nodeType === undefined ? value : undefined;\n }(typeof global === 'object' && global)) || checkGlobal(typeof self === 'object' && self) || checkGlobal(typeof window === 'object' && window) || mainContext || // set before strict mode in Ember loader/wrapper\n new Function('return this')(); // eval outside of strict mode\n\n function defaultTrue(v) {\n return v === false ? false : true;\n }\n\n function defaultFalse(v) {\n return v === true ? true : false;\n }\n\n /* globals module */\n /**\n The hash of environment variables used to control various configuration\n settings. To specify your own or override default settings, add the\n desired properties to a global hash named `EmberENV` (or `ENV` for\n backwards compatibility with earlier versions of Ember). The `EmberENV`\n hash must be created before loading Ember.\n \n @class EmberENV\n @type Object\n @public\n */\n var ENV = typeof global$1.EmberENV === 'object' && global$1.EmberENV || typeof global$1.ENV === 'object' && global$1.ENV || {};\n\n // ENABLE_ALL_FEATURES was documented, but you can't actually enable non optional features.\n if (ENV.ENABLE_ALL_FEATURES) {\n ENV.ENABLE_OPTIONAL_FEATURES = true;\n }\n\n /**\n Determines whether Ember should add to `Array`, `Function`, and `String`\n native object prototypes, a few extra methods in order to provide a more\n friendly API.\n \n We generally recommend leaving this option set to true however, if you need\n to turn it off, you can add the configuration property\n `EXTEND_PROTOTYPES` to `EmberENV` and set it to `false`.\n \n Note, when disabled (the default configuration for Ember Addons), you will\n instead have to access all methods and functions from the Ember\n namespace.\n \n @property EXTEND_PROTOTYPES\n @type Boolean\n @default true\n @for EmberENV\n @public\n */\n ENV.EXTEND_PROTOTYPES = function (obj) {\n if (obj === false) {\n return { String: false, Array: false, Function: false };\n } else if (!obj || obj === true) {\n return { String: true, Array: true, Function: true };\n } else {\n return {\n String: defaultTrue(obj.String),\n Array: defaultTrue(obj.Array),\n Function: defaultTrue(obj.Function)\n };\n }\n }(ENV.EXTEND_PROTOTYPES);\n\n /**\n The `LOG_STACKTRACE_ON_DEPRECATION` property, when true, tells Ember to log\n a full stack trace during deprecation warnings.\n \n @property LOG_STACKTRACE_ON_DEPRECATION\n @type Boolean\n @default true\n @for EmberENV\n @public\n */\n ENV.LOG_STACKTRACE_ON_DEPRECATION = defaultTrue(ENV.LOG_STACKTRACE_ON_DEPRECATION);\n\n /**\n The `LOG_VERSION` property, when true, tells Ember to log versions of all\n dependent libraries in use.\n \n @property LOG_VERSION\n @type Boolean\n @default true\n @for EmberENV\n @public\n */\n ENV.LOG_VERSION = defaultTrue(ENV.LOG_VERSION);\n\n /**\n Debug parameter you can turn on. This will log all bindings that fire to\n the console. This should be disabled in production code. Note that you\n can also enable this from the console or temporarily.\n \n @property LOG_BINDINGS\n @for EmberENV\n @type Boolean\n @default false\n @public\n */\n ENV.LOG_BINDINGS = defaultFalse(ENV.LOG_BINDINGS);\n\n ENV.RAISE_ON_DEPRECATION = defaultFalse(ENV.RAISE_ON_DEPRECATION);\n\n // check if window exists and actually is the global\n var hasDOM = typeof window !== 'undefined' && window === global$1 && window.document && window.document.createElement && !ENV.disableBrowserEnvironment; // is this a public thing?\n\n // legacy imports/exports/lookup stuff (should we keep this??)\n var originalContext = global$1.Ember || {};\n\n var context = {\n // import jQuery\n imports: originalContext.imports || global$1,\n // export Ember\n exports: originalContext.exports || global$1,\n // search for Namespaces\n lookup: originalContext.lookup || global$1\n };\n\n // TODO: cleanup single source of truth issues with this stuff\n var environment = hasDOM ? {\n hasDOM: true,\n isChrome: !!window.chrome && !window.opera,\n isFirefox: typeof InstallTrigger !== 'undefined',\n isPhantom: !!window.callPhantom,\n location: window.location,\n history: window.history,\n userAgent: window.navigator.userAgent,\n window: window\n } : {\n hasDOM: false,\n isChrome: false,\n isFirefox: false,\n isPhantom: false,\n location: null,\n history: null,\n userAgent: 'Lynx (textmode)',\n window: null\n };\n\n exports.ENV = ENV;\n exports.context = context;\n exports.environment = environment;\n});","enifed('ember-metal', ['exports', 'ember-environment', 'ember-utils', 'ember-debug', 'ember-babel', 'ember/features', '@glimmer/reference', 'require', 'ember-console', 'backburner'], function (exports, emberEnvironment, emberUtils, emberDebug, emberBabel, ember_features, _glimmer_reference, require, Logger, Backburner) {\n 'use strict';\n\n require = 'default' in require ? require['default'] : require;\n Logger = 'default' in Logger ? Logger['default'] : Logger;\n Backburner = 'default' in Backburner ? Backburner['default'] : Backburner;\n\n /**\n @module ember\n */\n\n /**\n This namespace contains all Ember methods and functions. Future versions of\n Ember may overwrite this namespace and therefore, you should avoid adding any\n new properties.\n \n At the heart of Ember is Ember-Runtime, a set of core functions that provide\n cross-platform compatibility and object property observing. Ember-Runtime is\n small and performance-focused so you can use it alongside other\n cross-platform libraries such as jQuery. For more details, see\n [Ember-Runtime](https://emberjs.com/api/modules/ember-runtime.html).\n \n @class Ember\n @static\n @public\n */\n var Ember = typeof emberEnvironment.context.imports.Ember === 'object' && emberEnvironment.context.imports.Ember || {},\n TransactionRunner,\n runner,\n _hasOwnProperty,\n _propertyIsEnumerable,\n getPrototypeOf,\n metaStore,\n setWithMandatorySetter,\n makeEnumerable;\n\n // Make sure these are set whether Ember was already defined or not\n Ember.isNamespace = true;\n Ember.toString = function () {\n return 'Ember';\n };\n\n /*\n When we render a rich template hierarchy, the set of events that\n *might* happen tends to be much larger than the set of events that\n actually happen. This implies that we should make listener creation &\n destruction cheap, even at the cost of making event dispatch more\n expensive.\n \n Thus we store a new listener with a single push and no new\n allocations, without even bothering to do deduplication -- we can\n save that for dispatch time, if an event actually happens.\n */\n\n /* listener flags */\n var ONCE = 1;\n var SUSPENDED = 2;\n\n var protoMethods = {\n addToListeners: function (eventName, target, method, flags) {\n if (this._listeners === undefined) {\n this._listeners = [];\n }\n this._listeners.push(eventName, target, method, flags);\n },\n _finalizeListeners: function () {\n if (this._listenersFinalized) {\n return;\n }\n if (this._listeners === undefined) {\n this._listeners = [];\n }\n var pointer = this.parent,\n listeners;\n while (pointer !== undefined) {\n listeners = pointer._listeners;\n\n if (listeners !== undefined) {\n this._listeners = this._listeners.concat(listeners);\n }\n if (pointer._listenersFinalized) {\n break;\n }\n pointer = pointer.parent;\n }\n this._listenersFinalized = true;\n },\n removeFromListeners: function (eventName, target, method, didRemove) {\n var pointer = this,\n listeners,\n index;\n while (pointer !== undefined) {\n listeners = pointer._listeners;\n\n if (listeners !== undefined) {\n for (index = listeners.length - 4; index >= 0; index -= 4) {\n if (listeners[index] === eventName && (!method || listeners[index + 1] === target && listeners[index + 2] === method)) {\n if (pointer === this) {\n // we are modifying our own list, so we edit directly\n if (typeof didRemove === 'function') {\n didRemove(eventName, target, listeners[index + 2]);\n }\n listeners.splice(index, 4);\n } else {\n // we are trying to remove an inherited listener, so we do\n // just-in-time copying to detach our own listeners from\n // our inheritance chain.\n this._finalizeListeners();\n return this.removeFromListeners(eventName, target, method);\n }\n }\n }\n }\n if (pointer._listenersFinalized) {\n break;\n }\n pointer = pointer.parent;\n }\n },\n matchingListeners: function (eventName) {\n var pointer = this,\n listeners,\n index,\n susIndex,\n resultIndex;\n var result = void 0;\n while (pointer !== undefined) {\n listeners = pointer._listeners;\n\n if (listeners !== undefined) {\n for (index = 0; index < listeners.length; index += 4) {\n if (listeners[index] === eventName) {\n result = result || [];\n pushUniqueListener(result, listeners, index);\n }\n }\n }\n if (pointer._listenersFinalized) {\n break;\n }\n pointer = pointer.parent;\n }\n var sus = this._suspendedListeners;\n if (sus !== undefined && result !== undefined) {\n for (susIndex = 0; susIndex < sus.length; susIndex += 3) {\n if (eventName === sus[susIndex]) {\n for (resultIndex = 0; resultIndex < result.length; resultIndex += 3) {\n if (result[resultIndex] === sus[susIndex + 1] && result[resultIndex + 1] === sus[susIndex + 2]) {\n result[resultIndex + 2] |= SUSPENDED;\n }\n }\n }\n }\n }\n return result;\n },\n suspendListeners: function (eventNames, target, method, callback) {\n var sus = this._suspendedListeners,\n i,\n _i;\n if (sus === undefined) {\n sus = this._suspendedListeners = [];\n }\n for (i = 0; i < eventNames.length; i++) {\n sus.push(eventNames[i], target, method);\n }\n try {\n return callback.call(target);\n } finally {\n if (sus.length === eventNames.length) {\n this._suspendedListeners = undefined;\n } else {\n for (_i = sus.length - 3; _i >= 0; _i -= 3) {\n if (sus[_i + 1] === target && sus[_i + 2] === method && eventNames.indexOf(sus[_i]) !== -1) {\n sus.splice(_i, 3);\n }\n }\n }\n }\n },\n watchedEvents: function () {\n var pointer = this,\n listeners,\n index;\n var names = {};\n while (pointer !== undefined) {\n listeners = pointer._listeners;\n\n if (listeners !== undefined) {\n for (index = 0; index < listeners.length; index += 4) {\n names[listeners[index]] = true;\n }\n }\n if (pointer._listenersFinalized) {\n break;\n }\n pointer = pointer.parent;\n }\n return Object.keys(names);\n }\n };\n\n function pushUniqueListener(destination, source, index) {\n var target = source[index + 1],\n destinationIndex;\n var method = source[index + 2];\n for (destinationIndex = 0; destinationIndex < destination.length; destinationIndex += 3) {\n if (destination[destinationIndex] === target && destination[destinationIndex + 1] === method) {\n return;\n }\n }\n destination.push(target, method, source[index + 3]);\n }\n\n /**\n @module @ember/object\n */\n /*\n The event system uses a series of nested hashes to store listeners on an\n object. When a listener is registered, or when an event arrives, these\n hashes are consulted to determine which target and action pair to invoke.\n \n The hashes are stored in the object's meta hash, and look like this:\n \n // Object's meta hash\n {\n listeners: { // variable name: `listenerSet`\n \"foo:changed\": [ // variable name: `actions`\n target, method, flags\n ]\n }\n }\n \n */\n\n /**\n Add an event listener\n \n @method addListener\n @static\n @for @ember/object/events\n @param obj\n @param {String} eventName\n @param {Object|Function} target A target object or a function\n @param {Function|String} method A function or the name of a function to be called on `target`\n @param {Boolean} once A flag whether a function should only be called once\n @public\n */\n function addListener(obj, eventName, target, method, once) {\n true && !(!!obj && !!eventName) && emberDebug.assert('You must pass at least an object and event name to addListener', !!obj && !!eventName);\n true && !(eventName !== 'didInitAttrs') && emberDebug.deprecate('didInitAttrs called in ' + (obj && obj.toString && obj.toString()) + '.', eventName !== 'didInitAttrs', {\n id: 'ember-views.did-init-attrs',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x#toc_ember-component-didinitattrs'\n });\n\n if (!method && 'function' === typeof target) {\n method = target;\n target = null;\n }\n\n var flags = 0;\n if (once) {\n flags |= ONCE;\n }\n\n meta(obj).addToListeners(eventName, target, method, flags);\n\n if ('function' === typeof obj.didAddListener) {\n obj.didAddListener(eventName, target, method);\n }\n }\n\n /**\n Remove an event listener\n \n Arguments should match those passed to `addListener`.\n \n @method removeListener\n @static\n @for @ember/object/events\n @param obj\n @param {String} eventName\n @param {Object|Function} target A target object or a function\n @param {Function|String} method A function or the name of a function to be called on `target`\n @public\n */\n function removeListener(obj, eventName, target, method) {\n true && !(!!obj && !!eventName) && emberDebug.assert('You must pass at least an object and event name to removeListener', !!obj && !!eventName);\n\n if (!method && 'function' === typeof target) {\n method = target;\n target = null;\n }\n\n var func = 'function' === typeof obj.didRemoveListener ? obj.didRemoveListener.bind(obj) : function () {};\n meta(obj).removeFromListeners(eventName, target, method, func);\n }\n\n /**\n Suspend listener during callback.\n \n This should only be used by the target of the event listener\n when it is taking an action that would cause the event, e.g.\n an object might suspend its property change listener while it is\n setting that property.\n \n @method suspendListener\n @static\n @for @ember/object/events\n \n @private\n @param obj\n @param {String} eventName\n @param {Object|Function} target A target object or a function\n @param {Function|String} method A function or the name of a function to be called on `target`\n @param {Function} callback\n */\n function suspendListener(obj, eventName, target, method, callback) {\n return suspendListeners(obj, [eventName], target, method, callback);\n }\n\n /**\n Suspends multiple listeners during a callback.\n \n @method suspendListeners\n @static\n @for @ember/object/events\n \n @private\n @param obj\n @param {Array} eventNames Array of event names\n @param {Object|Function} target A target object or a function\n @param {Function|String} method A function or the name of a function to be called on `target`\n @param {Function} callback\n */\n function suspendListeners(obj, eventNames, target, method, callback) {\n if (!method && 'function' === typeof target) {\n method = target;\n target = null;\n }\n return meta(obj).suspendListeners(eventNames, target, method, callback);\n }\n\n /**\n Return a list of currently watched events\n \n @private\n @method watchedEvents\n @static\n @for @ember/object/events\n @param obj\n */\n\n\n /**\n Send an event. The execution of suspended listeners\n is skipped, and once listeners are removed. A listener without\n a target is executed on the passed object. If an array of actions\n is not passed, the actions stored on the passed object are invoked.\n \n @method sendEvent\n @static\n @for @ember/object/events\n @param obj\n @param {String} eventName\n @param {Array} params Optional parameters for each listener.\n @param {Array} actions Optional array of actions (listeners).\n @param {Meta} meta Optional meta to lookup listeners\n @return true\n @public\n */\n function sendEvent(obj, eventName, params, actions, _meta) {\n var meta$$1, i, target, method, flags;\n\n if (actions === undefined) {\n meta$$1 = _meta === undefined ? exports.peekMeta(obj) : _meta;\n\n actions = typeof meta$$1 === 'object' && meta$$1 !== null && meta$$1.matchingListeners(eventName);\n }\n\n if (actions === undefined || actions.length === 0) {\n return false;\n }\n\n for (i = actions.length - 3; i >= 0; i -= 3) {\n // looping in reverse for once listeners\n target = actions[i];\n method = actions[i + 1];\n flags = actions[i + 2];\n\n\n if (!method) {\n continue;\n }\n if (flags & SUSPENDED) {\n continue;\n }\n if (flags & ONCE) {\n removeListener(obj, eventName, target, method);\n }\n if (!target) {\n target = obj;\n }\n if ('string' === typeof method) {\n if (params) {\n emberUtils.applyStr(target, method, params);\n } else {\n target[method]();\n }\n } else {\n if (params) {\n method.apply(target, params);\n } else {\n method.call(target);\n }\n }\n }\n return true;\n }\n\n /**\n @private\n @method hasListeners\n @static\n @for @ember/object/events\n @param obj\n @param {String} eventName\n */\n\n\n /**\n @private\n @method listenersFor\n @static\n @for @ember/object/events\n @param obj\n @param {String} eventName\n */\n function listenersFor(obj, eventName) {\n var ret = [],\n i,\n target,\n method;\n var meta$$1 = exports.peekMeta(obj);\n var actions = meta$$1 !== undefined ? meta$$1.matchingListeners(eventName) : undefined;\n\n if (actions === undefined) {\n return ret;\n }\n\n for (i = 0; i < actions.length; i += 3) {\n target = actions[i];\n method = actions[i + 1];\n\n ret.push([target, method]);\n }\n\n return ret;\n }\n\n /**\n Define a property as a function that should be executed when\n a specified event or events are triggered.\n \n \n ``` javascript\n import EmberObject from '@ember/object';\n import { on } from '@ember/object/evented';\n import { sendEvent } from '@ember/object/events';\n \n let Job = EmberObject.extend({\n logCompleted: on('completed', function() {\n console.log('Job completed!');\n })\n });\n \n let job = Job.create();\n \n sendEvent(job, 'completed'); // Logs 'Job completed!'\n ```\n \n @method on\n @static\n @for @ember/object/evented\n @param {String} eventNames*\n @param {Function} func\n @return func\n @public\n */\n\n\n var hasViews = function () {\n return false;\n };\n\n function makeTag() {\n return new _glimmer_reference.DirtyableTag();\n }\n\n function tagFor(object, _meta) {\n var meta$$1;\n\n if (typeof object === 'object' && object !== null) {\n meta$$1 = _meta === undefined ? meta(object) : _meta;\n\n return meta$$1.writableTag(makeTag);\n } else {\n return _glimmer_reference.CONSTANT_TAG;\n }\n }\n\n function markObjectAsDirty(meta$$1, propertyKey) {\n var objectTag = meta$$1.readableTag();\n\n if (objectTag !== undefined) {\n objectTag.dirty();\n }\n\n var tags = meta$$1.readableTags();\n var propertyTag = tags !== undefined ? tags[propertyKey] : undefined;\n\n if (propertyTag !== undefined) {\n propertyTag.dirty();\n }\n\n if (propertyKey === 'content' && meta$$1.isProxy()) {\n objectTag.contentDidChange();\n }\n\n if (objectTag !== undefined || propertyTag !== undefined) {\n ensureRunloop();\n }\n }\n\n var backburner = void 0;\n function ensureRunloop() {\n if (backburner === undefined) {\n backburner = require('ember-metal').run.backburner;\n }\n\n if (hasViews()) {\n backburner.ensureInstance();\n }\n }\n\n /*\n this.observerSet = {\n [senderGuid]: { // variable name: `keySet`\n [keyName]: listIndex\n }\n },\n this.observers = [\n {\n sender: obj,\n keyName: keyName,\n eventName: eventName,\n listeners: [\n [target, method, flags]\n ]\n },\n ...\n ]\n */\n\n var ObserverSet = function () {\n function ObserverSet() {\n\n this.clear();\n }\n\n ObserverSet.prototype.add = function (sender, keyName, eventName) {\n var observerSet = this.observerSet;\n var observers = this.observers;\n var senderGuid = emberUtils.guidFor(sender);\n var keySet = observerSet[senderGuid];\n\n if (keySet === undefined) {\n observerSet[senderGuid] = keySet = {};\n }\n\n var index = keySet[keyName];\n if (index === undefined) {\n index = observers.push({\n sender: sender,\n keyName: keyName,\n eventName: eventName,\n listeners: []\n }) - 1;\n keySet[keyName] = index;\n }\n return observers[index].listeners;\n };\n\n ObserverSet.prototype.flush = function () {\n var observers = this.observers,\n i;\n var observer = void 0,\n sender = void 0;\n this.clear();\n for (i = 0; i < observers.length; ++i) {\n observer = observers[i];\n sender = observer.sender;\n if (sender.isDestroying || sender.isDestroyed) {\n continue;\n }\n sendEvent(sender, observer.eventName, [sender, observer.keyName], observer.listeners);\n }\n };\n\n ObserverSet.prototype.clear = function () {\n this.observerSet = {};\n this.observers = [];\n };\n\n return ObserverSet;\n }();\n\n /**\n @module ember\n */\n var id = 0;\n\n // Returns whether Type(value) is Object according to the terminology in the spec\n function isObject$1(value) {\n return typeof value === 'object' && value !== null || typeof value === 'function';\n }\n\n /*\n * @class Ember.WeakMap\n * @public\n * @category ember-metal-weakmap\n *\n * A partial polyfill for [WeakMap](http://www.ecma-international.org/ecma-262/6.0/#sec-weakmap-objects).\n *\n * There is a small but important caveat. This implementation assumes that the\n * weak map will live longer (in the sense of garbage collection) than all of its\n * keys, otherwise it is possible to leak the values stored in the weak map. In\n * practice, most use cases satisfy this limitation which is why it is included\n * in ember-metal.\n */\n var WeakMapPolyfill = function () {\n function WeakMapPolyfill(iterable) {\n var i, _iterable$i, key, value;\n\n this._id = emberUtils.GUID_KEY + id++;\n\n if (iterable === null || iterable === undefined) {} else if (Array.isArray(iterable)) {\n for (i = 0; i < iterable.length; i++) {\n _iterable$i = iterable[i], key = _iterable$i[0], value = _iterable$i[1];\n\n\n this.set(key, value);\n }\n } else {\n throw new TypeError('The weak map constructor polyfill only supports an array argument');\n }\n }\n\n /*\n * @method get\n * @param key {Object | Function}\n * @return {Any} stored value\n */\n\n WeakMapPolyfill.prototype.get = function (obj) {\n if (!isObject$1(obj)) {\n return undefined;\n }\n\n var meta$$1 = exports.peekMeta(obj),\n map,\n val;\n if (meta$$1 !== undefined) {\n map = meta$$1.readableWeak();\n\n if (map !== undefined) {\n val = map[this._id];\n\n if (val === UNDEFINED) {\n return undefined;\n }\n return val;\n }\n }\n };\n\n /*\n * @method set\n * @param key {Object | Function}\n * @param value {Any}\n * @return {WeakMap} the weak map\n */\n\n WeakMapPolyfill.prototype.set = function (obj, value) {\n if (!isObject$1(obj)) {\n throw new TypeError('Invalid value used as weak map key');\n }\n\n if (value === undefined) {\n value = UNDEFINED;\n }\n\n meta(obj).writableWeak()[this._id] = value;\n\n return this;\n };\n\n /*\n * @method has\n * @param key {Object | Function}\n * @return {boolean} if the key exists\n */\n\n WeakMapPolyfill.prototype.has = function (obj) {\n if (!isObject$1(obj)) {\n return false;\n }\n\n var meta$$1 = exports.peekMeta(obj),\n map;\n if (meta$$1 !== undefined) {\n map = meta$$1.readableWeak();\n\n if (map !== undefined) {\n return map[this._id] !== undefined;\n }\n }\n\n return false;\n };\n\n /*\n * @method delete\n * @param key {Object | Function}\n * @return {boolean} if the key was deleted\n */\n\n WeakMapPolyfill.prototype.delete = function (obj) {\n if (this.has(obj)) {\n delete exports.peekMeta(obj).writableWeak()[this._id];\n return true;\n } else {\n return false;\n }\n };\n\n /*\n * @method toString\n * @return {String}\n */\n\n WeakMapPolyfill.prototype.toString = function () {\n return '[object WeakMap]';\n };\n\n return WeakMapPolyfill;\n }();\n\n var WeakMap$1 = emberUtils.HAS_NATIVE_WEAKMAP ? WeakMap : WeakMapPolyfill;\n\n exports.runInTransaction = void 0;\n exports.didRender = void 0;\n exports.assertNotRendered = void 0;\n\n // detect-backtracking-rerender by default is debug build only\n // detect-glimmer-allow-backtracking-rerender can be enabled in custom builds\n if (ember_features.EMBER_GLIMMER_DETECT_BACKTRACKING_RERENDER || ember_features.EMBER_GLIMMER_ALLOW_BACKTRACKING_RERENDER) {\n\n // there are 4 states\n\n // NATIVE WEAKMAP AND DEBUG\n // tracks lastRef and lastRenderedIn per rendered object and key during a transaction\n // release everything via normal weakmap semantics by just derefencing the weakmap\n\n // NATIVE WEAKMAP AND RELEASE\n // tracks transactionId per rendered object and key during a transaction\n // release everything via normal weakmap semantics by just derefencing the weakmap\n\n // WEAKMAP POLYFILL AND DEBUG\n // tracks lastRef and lastRenderedIn per rendered object and key during a transaction\n // since lastRef retains a lot of app state (will have a ref to the Container)\n // if the object rendered is retained (like a immutable POJO in module state)\n // during acceptance tests this adds up and obfuscates finding other leaks.\n\n // WEAKMAP POLYFILL AND RELEASE\n // tracks transactionId per rendered object and key during a transaction\n // leaks it because small and likely not worth tracking it since it will only\n // be leaked if the object is retained\n\n TransactionRunner = function () {\n function TransactionRunner() {\n\n this.transactionId = 0;\n this.inTransaction = false;\n this.shouldReflush = false;\n this.weakMap = new WeakMap$1();\n {\n // track templates\n this.debugStack = undefined;\n\n if (!emberUtils.HAS_NATIVE_WEAKMAP) {\n // DEBUG AND POLYFILL\n // needs obj tracking\n this.objs = [];\n }\n }\n }\n\n TransactionRunner.prototype.runInTransaction = function (context$$1, methodName) {\n this.before(context$$1);\n try {\n context$$1[methodName]();\n } finally {\n this.after();\n }\n return this.shouldReflush;\n };\n\n TransactionRunner.prototype.didRender = function (object, key, reference) {\n if (!this.inTransaction) {\n return;\n }\n {\n this.setKey(object, key, {\n lastRef: reference,\n lastRenderedIn: this.debugStack.peek()\n });\n }\n };\n\n TransactionRunner.prototype.assertNotRendered = function (object, key) {\n var _getKey, lastRef, lastRenderedIn, currentlyIn, parts, label, message;\n\n if (!this.inTransaction) {\n return;\n }\n if (this.hasRendered(object, key)) {\n {\n _getKey = this.getKey(object, key), lastRef = _getKey.lastRef, lastRenderedIn = _getKey.lastRenderedIn;\n currentlyIn = this.debugStack.peek();\n parts = [];\n label = void 0;\n\n\n if (lastRef !== undefined) {\n while (lastRef && lastRef._propertyKey) {\n parts.unshift(lastRef._propertyKey);\n lastRef = lastRef._parentReference;\n }\n\n label = parts.join('.');\n } else {\n label = 'the same value';\n }\n\n message = 'You modified \"' + label + '\" twice on ' + object + ' in a single render. It was rendered in ' + lastRenderedIn + ' and modified in ' + currentlyIn + '. This was unreliable and slow in Ember 1.x and';\n\n\n if (ember_features.EMBER_GLIMMER_ALLOW_BACKTRACKING_RERENDER) {\n true && !false && emberDebug.deprecate(message + ' will be removed in Ember 3.0.', false, { id: 'ember-views.render-double-modify', until: '3.0.0' });\n } else {\n true && !false && emberDebug.assert(message + ' is no longer supported. See https://github.com/emberjs/ember.js/issues/13948 for more details.', false);\n }\n }\n\n this.shouldReflush = true;\n }\n };\n\n TransactionRunner.prototype.hasRendered = function (object, key) {\n if (!this.inTransaction) {\n return false;\n }\n {\n return this.getKey(object, key) !== undefined;\n }\n return this.getKey(object, key) === this.transactionId;\n };\n\n TransactionRunner.prototype.before = function (context$$1) {\n this.inTransaction = true;\n this.shouldReflush = false;\n {\n this.debugStack = context$$1.env.debugStack;\n }\n };\n\n TransactionRunner.prototype.after = function () {\n this.transactionId++;\n this.inTransaction = false;\n {\n this.debugStack = undefined;\n }\n this.clearObjectMap();\n };\n\n TransactionRunner.prototype.createMap = function (object) {\n var map = Object.create(null);\n this.weakMap.set(object, map);\n if (true && !emberUtils.HAS_NATIVE_WEAKMAP) {\n // POLYFILL AND DEBUG\n // requires tracking objects\n this.objs.push(object);\n }\n return map;\n };\n\n TransactionRunner.prototype.getOrCreateMap = function (object) {\n var map = this.weakMap.get(object);\n if (map === undefined) {\n map = this.createMap(object);\n }\n return map;\n };\n\n TransactionRunner.prototype.setKey = function (object, key, value) {\n var map = this.getOrCreateMap(object);\n map[key] = value;\n };\n\n TransactionRunner.prototype.getKey = function (object, key) {\n var map = this.weakMap.get(object);\n if (map !== undefined) {\n return map[key];\n }\n };\n\n TransactionRunner.prototype.clearObjectMap = function () {\n var objs, weakMap, i;\n\n if (emberUtils.HAS_NATIVE_WEAKMAP) {\n // NATIVE AND (DEBUG OR RELEASE)\n // if we have a real native weakmap\n // releasing the ref will allow the values to be GCed\n this.weakMap = new WeakMap$1();\n } else {\n // POLYFILL AND DEBUG\n // with a polyfill the weakmap keys must be cleared since\n // they have the last reference, acceptance tests will leak\n // the container if you render a immutable object retained\n // in module scope.\n objs = this.objs, weakMap = this.weakMap;\n\n\n this.objs = [];\n for (i = 0; i < objs.length; i++) {\n weakMap.delete(objs[i]);\n }\n }\n // POLYFILL AND RELEASE\n // we leak the key map if the object is retained but this is\n // a POJO of keys to transaction ids\n };\n\n return TransactionRunner;\n }();\n runner = new TransactionRunner();\n\n\n exports.runInTransaction = runner.runInTransaction.bind(runner);\n exports.didRender = runner.didRender.bind(runner);\n exports.assertNotRendered = runner.assertNotRendered.bind(runner);\n } else {\n // in production do nothing to detect reflushes\n exports.runInTransaction = function (context$$1, methodName) {\n context$$1[methodName]();\n return false;\n };\n }\n\n /**\n @module ember\n @private\n */\n\n var PROPERTY_DID_CHANGE = emberUtils.symbol('PROPERTY_DID_CHANGE');\n\n var beforeObserverSet = new ObserverSet();\n var observerSet = new ObserverSet();\n var deferred = 0;\n\n // ..........................................................\n // PROPERTY CHANGES\n //\n\n /**\n This function is called just before an object property is about to change.\n It will notify any before observers and prepare caches among other things.\n \n Normally you will not need to call this method directly but if for some\n reason you can't directly watch a property you can invoke this method\n manually along with `Ember.propertyDidChange()` which you should call just\n after the property value changes.\n \n @method propertyWillChange\n @for Ember\n @param {Object} obj The object with the property that will change\n @param {String} keyName The property key (or path) that will change.\n @return {void}\n @private\n */\n function propertyWillChange(obj, keyName, _meta) {\n var meta$$1 = _meta === undefined ? exports.peekMeta(obj) : _meta;\n if (meta$$1 !== undefined && !meta$$1.isInitialized(obj)) {\n return;\n }\n\n var watching = meta$$1 !== undefined && meta$$1.peekWatching(keyName) > 0;\n var possibleDesc = obj[keyName];\n var isDescriptor = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor;\n\n if (isDescriptor && possibleDesc.willChange) {\n possibleDesc.willChange(obj, keyName);\n }\n\n if (watching) {\n dependentKeysWillChange(obj, keyName, meta$$1);\n chainsWillChange(obj, keyName, meta$$1);\n notifyBeforeObservers(obj, keyName, meta$$1);\n }\n }\n\n /**\n This function is called just after an object property has changed.\n It will notify any observers and clear caches among other things.\n \n Normally you will not need to call this method directly but if for some\n reason you can't directly watch a property you can invoke this method\n manually along with `Ember.propertyWillChange()` which you should call just\n before the property value changes.\n \n @method propertyDidChange\n @for Ember\n @param {Object} obj The object with the property that will change\n @param {String} keyName The property key (or path) that will change.\n @param {Meta} meta The objects meta.\n @return {void}\n @private\n */\n function propertyDidChange(obj, keyName, _meta) {\n var meta$$1 = _meta === undefined ? exports.peekMeta(obj) : _meta;\n var hasMeta = meta$$1 !== undefined;\n\n if (hasMeta && !meta$$1.isInitialized(obj)) {\n return;\n }\n\n var possibleDesc = obj[keyName];\n var isDescriptor = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor;\n\n // shouldn't this mean that we're watching this key?\n if (isDescriptor && possibleDesc.didChange) {\n possibleDesc.didChange(obj, keyName);\n }\n\n if (hasMeta && meta$$1.peekWatching(keyName) > 0) {\n dependentKeysDidChange(obj, keyName, meta$$1);\n chainsDidChange(obj, keyName, meta$$1);\n notifyObservers(obj, keyName, meta$$1);\n }\n\n if (obj[PROPERTY_DID_CHANGE]) {\n obj[PROPERTY_DID_CHANGE](keyName);\n }\n\n if (hasMeta) {\n if (meta$$1.isSourceDestroying()) {\n return;\n }\n markObjectAsDirty(meta$$1, keyName);\n }\n\n if (ember_features.EMBER_GLIMMER_DETECT_BACKTRACKING_RERENDER || ember_features.EMBER_GLIMMER_ALLOW_BACKTRACKING_RERENDER) {\n exports.assertNotRendered(obj, keyName, meta$$1);\n }\n }\n\n var WILL_SEEN = void 0;\n var DID_SEEN = void 0;\n // called whenever a property is about to change to clear the cache of any dependent keys (and notify those properties of changes, etc...)\n function dependentKeysWillChange(obj, depKey, meta$$1) {\n if (meta$$1.isSourceDestroying() || !meta$$1.hasDeps(depKey)) {\n return;\n }\n var seen = WILL_SEEN;\n var top = !seen;\n\n if (top) {\n seen = WILL_SEEN = {};\n }\n\n iterDeps(propertyWillChange, obj, depKey, seen, meta$$1);\n\n if (top) {\n WILL_SEEN = null;\n }\n }\n\n // called whenever a property has just changed to update dependent keys\n function dependentKeysDidChange(obj, depKey, meta$$1) {\n if (meta$$1.isSourceDestroying() || !meta$$1.hasDeps(depKey)) {\n return;\n }\n var seen = DID_SEEN;\n var top = !seen;\n\n if (top) {\n seen = DID_SEEN = {};\n }\n\n iterDeps(propertyDidChange, obj, depKey, seen, meta$$1);\n\n if (top) {\n DID_SEEN = null;\n }\n }\n\n function iterDeps(method, obj, depKey, seen, meta$$1) {\n var possibleDesc = void 0,\n isDescriptor = void 0;\n var guid = emberUtils.guidFor(obj);\n var current = seen[guid];\n\n if (!current) {\n current = seen[guid] = {};\n }\n\n if (current[depKey]) {\n return;\n }\n\n current[depKey] = true;\n\n meta$$1.forEachInDeps(depKey, function (key, value) {\n if (!value) {\n return;\n }\n\n possibleDesc = obj[key];\n isDescriptor = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor;\n\n if (isDescriptor && possibleDesc._suspended === obj) {\n return;\n }\n\n method(obj, key, meta$$1);\n });\n }\n\n function chainsWillChange(obj, keyName, meta$$1) {\n var chainWatchers = meta$$1.readableChainWatchers();\n if (chainWatchers !== undefined) {\n chainWatchers.notify(keyName, false, propertyWillChange);\n }\n }\n\n function chainsDidChange(obj, keyName, meta$$1) {\n var chainWatchers = meta$$1.readableChainWatchers();\n if (chainWatchers !== undefined) {\n chainWatchers.notify(keyName, true, propertyDidChange);\n }\n }\n\n function overrideChains(obj, keyName, meta$$1) {\n var chainWatchers = meta$$1.readableChainWatchers();\n if (chainWatchers !== undefined) {\n chainWatchers.revalidate(keyName);\n }\n }\n\n /**\n @method beginPropertyChanges\n @chainable\n @private\n */\n function beginPropertyChanges() {\n deferred++;\n }\n\n /**\n @method endPropertyChanges\n @private\n */\n function endPropertyChanges() {\n deferred--;\n if (deferred <= 0) {\n beforeObserverSet.clear();\n observerSet.flush();\n }\n }\n\n /**\n Make a series of property changes together in an\n exception-safe way.\n \n ```javascript\n Ember.changeProperties(function() {\n obj1.set('foo', mayBlowUpWhenSet);\n obj2.set('bar', baz);\n });\n ```\n \n @method changeProperties\n @param {Function} callback\n @param [binding]\n @private\n */\n function changeProperties(callback, binding) {\n beginPropertyChanges();\n try {\n callback.call(binding);\n } finally {\n endPropertyChanges();\n }\n }\n\n function indexOf(array, target, method) {\n var index = -1,\n i;\n // hashes are added to the end of the event array\n // so it makes sense to start searching at the end\n // of the array and search in reverse\n for (i = array.length - 3; i >= 0; i -= 3) {\n if (target === array[i] && method === array[i + 1]) {\n index = i;\n break;\n }\n }\n return index;\n }\n\n function accumulateListeners(obj, eventName, otherActions, meta$$1) {\n var actions = meta$$1.matchingListeners(eventName),\n i,\n target,\n method,\n flags,\n actionIndex;\n if (actions === undefined) {\n return;\n }\n var newActions = [];\n\n for (i = actions.length - 3; i >= 0; i -= 3) {\n target = actions[i];\n method = actions[i + 1];\n flags = actions[i + 2];\n actionIndex = indexOf(otherActions, target, method);\n\n\n if (actionIndex === -1) {\n otherActions.push(target, method, flags);\n newActions.push(target, method, flags);\n }\n }\n\n return newActions;\n }\n\n function notifyBeforeObservers(obj, keyName, meta$$1) {\n if (meta$$1.isSourceDestroying()) {\n return;\n }\n\n var eventName = keyName + ':before';\n var listeners = void 0,\n added = void 0;\n if (deferred > 0) {\n listeners = beforeObserverSet.add(obj, keyName, eventName);\n added = accumulateListeners(obj, eventName, listeners, meta$$1);\n }\n sendEvent(obj, eventName, [obj, keyName], added);\n }\n\n function notifyObservers(obj, keyName, meta$$1) {\n if (meta$$1.isSourceDestroying()) {\n return;\n }\n\n var eventName = keyName + ':change';\n var listeners = void 0;\n if (deferred > 0) {\n listeners = observerSet.add(obj, keyName, eventName);\n accumulateListeners(obj, eventName, listeners, meta$$1);\n } else {\n sendEvent(obj, eventName, [obj, keyName]);\n }\n }\n\n /**\n @module @ember/object\n */\n\n // ..........................................................\n // DESCRIPTOR\n //\n\n /**\n Objects of this type can implement an interface to respond to requests to\n get and set. The default implementation handles simple properties.\n \n @class Descriptor\n @private\n */\n function Descriptor() {\n this.isDescriptor = true;\n }\n\n var REDEFINE_SUPPORTED = function () {\n // https://github.com/spalger/kibana/commit/b7e35e6737df585585332857a4c397dc206e7ff9\n var a = Object.create(Object.prototype, {\n prop: {\n configurable: true,\n value: 1\n }\n });\n\n Object.defineProperty(a, 'prop', {\n configurable: true,\n value: 2\n });\n\n return a.prop === 2;\n }();\n // ..........................................................\n // DEFINING PROPERTIES API\n //\n\n function MANDATORY_SETTER_FUNCTION(name) {\n function SETTER_FUNCTION(value) {\n var m = exports.peekMeta(this);\n if (!m.isInitialized(this)) {\n m.writeValues(name, value);\n } else {\n true && !false && emberDebug.assert('You must use set() to set the `' + name + '` property (of ' + this + ') to `' + value + '`.', false);\n }\n }\n\n SETTER_FUNCTION.isMandatorySetter = true;\n return SETTER_FUNCTION;\n }\n\n function DEFAULT_GETTER_FUNCTION(name) {\n return function () {\n var meta$$1 = exports.peekMeta(this);\n if (meta$$1 !== undefined) {\n return meta$$1.peekValues(name);\n }\n };\n }\n\n function INHERITING_GETTER_FUNCTION(name) {\n function IGETTER_FUNCTION() {\n var meta$$1 = exports.peekMeta(this),\n proto;\n var val = void 0;\n if (meta$$1 !== undefined) {\n val = meta$$1.readInheritedValue('values', name);\n }\n\n if (val === UNDEFINED) {\n proto = Object.getPrototypeOf(this);\n\n return proto && proto[name];\n } else {\n return val;\n }\n }\n\n IGETTER_FUNCTION.isInheritingGetter = true;\n return IGETTER_FUNCTION;\n }\n\n /**\n NOTE: This is a low-level method used by other parts of the API. You almost\n never want to call this method directly. Instead you should use\n `mixin()` to define new properties.\n \n Defines a property on an object. This method works much like the ES5\n `Object.defineProperty()` method except that it can also accept computed\n properties and other special descriptors.\n \n Normally this method takes only three parameters. However if you pass an\n instance of `Descriptor` as the third param then you can pass an\n optional value as the fourth parameter. This is often more efficient than\n creating new descriptor hashes for each property.\n \n ## Examples\n \n ```javascript\n import { defineProperty, computed } from '@ember/object';\n \n // ES5 compatible mode\n defineProperty(contact, 'firstName', {\n writable: true,\n configurable: false,\n enumerable: true,\n value: 'Charles'\n });\n \n // define a simple property\n defineProperty(contact, 'lastName', undefined, 'Jolley');\n \n // define a computed property\n defineProperty(contact, 'fullName', computed('firstName', 'lastName', function() {\n return this.firstName+' '+this.lastName;\n }));\n ```\n \n @private\n @method defineProperty\n @for @ember/object\n @param {Object} obj the object to define this property on. This may be a prototype.\n @param {String} keyName the name of the property\n @param {Descriptor} [desc] an instance of `Descriptor` (typically a\n computed property) or an ES5 descriptor.\n You must provide this or `data` but not both.\n @param {*} [data] something other than a descriptor, that will\n become the explicit value of this property.\n */\n function defineProperty(obj, keyName, desc, data, meta$$1) {\n if (meta$$1 === undefined) {\n meta$$1 = meta(obj);\n }\n\n var watchEntry = meta$$1.peekWatching(keyName),\n defaultDescriptor;\n var watching = watchEntry !== undefined && watchEntry > 0;\n var possibleDesc = obj[keyName];\n var isDescriptor = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor;\n\n if (isDescriptor) {\n possibleDesc.teardown(obj, keyName, meta$$1);\n }\n\n var value = void 0;\n if (desc instanceof Descriptor) {\n value = desc;\n if (ember_features.MANDATORY_SETTER) {\n if (watching) {\n Object.defineProperty(obj, keyName, {\n configurable: true,\n enumerable: true,\n writable: true,\n value: value\n });\n } else {\n obj[keyName] = value;\n }\n } else {\n obj[keyName] = value;\n }\n\n didDefineComputedProperty(obj.constructor);\n\n if (typeof desc.setup === 'function') {\n desc.setup(obj, keyName);\n }\n } else if (desc === undefined || desc === null) {\n value = data;\n\n if (ember_features.MANDATORY_SETTER) {\n if (watching) {\n meta$$1.writeValues(keyName, data);\n\n defaultDescriptor = {\n configurable: true,\n enumerable: true,\n set: MANDATORY_SETTER_FUNCTION(keyName),\n get: DEFAULT_GETTER_FUNCTION(keyName)\n };\n\n\n if (REDEFINE_SUPPORTED) {\n Object.defineProperty(obj, keyName, defaultDescriptor);\n } else {\n handleBrokenPhantomDefineProperty(obj, keyName, defaultDescriptor);\n }\n } else {\n obj[keyName] = data;\n }\n } else {\n obj[keyName] = data;\n }\n } else {\n value = desc;\n\n // fallback to ES5\n Object.defineProperty(obj, keyName, desc);\n }\n\n // if key is being watched, override chains that\n // were initialized with the prototype\n if (watching) {\n overrideChains(obj, keyName, meta$$1);\n }\n\n // The `value` passed to the `didDefineProperty` hook is\n // either the descriptor or data, whichever was passed.\n if (typeof obj.didDefineProperty === 'function') {\n obj.didDefineProperty(obj, keyName, value);\n }\n\n return this;\n }\n\n var hasCachedComputedProperties = false;\n\n\n function didDefineComputedProperty(constructor) {\n if (hasCachedComputedProperties === false) {\n return;\n }\n var cache = meta(constructor).readableCache();\n\n if (cache && cache._computedProperties !== undefined) {\n cache._computedProperties = undefined;\n }\n }\n\n function handleBrokenPhantomDefineProperty(obj, keyName, desc) {\n // https://github.com/ariya/phantomjs/issues/11856\n Object.defineProperty(obj, keyName, { configurable: true, writable: true, value: 'iCry' });\n Object.defineProperty(obj, keyName, desc);\n }\n\n var handleMandatorySetter = void 0;\n\n function watchKey(obj, keyName, _meta) {\n if (typeof obj !== 'object' || obj === null) {\n return;\n }\n\n var meta$$1 = _meta === undefined ? meta(obj) : _meta,\n possibleDesc,\n isDescriptor;\n var count = meta$$1.peekWatching(keyName) || 0;\n meta$$1.writeWatching(keyName, count + 1);\n\n if (count === 0) {\n // activate watching first time\n possibleDesc = obj[keyName];\n isDescriptor = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor;\n\n if (isDescriptor && possibleDesc.willWatch) {\n possibleDesc.willWatch(obj, keyName, meta$$1);\n }\n\n if (typeof obj.willWatchProperty === 'function') {\n obj.willWatchProperty(keyName);\n }\n\n if (ember_features.MANDATORY_SETTER) {\n // NOTE: this is dropped for prod + minified builds\n handleMandatorySetter(meta$$1, obj, keyName);\n }\n }\n }\n\n if (ember_features.MANDATORY_SETTER) {\n _hasOwnProperty = function (obj, key) {\n return Object.prototype.hasOwnProperty.call(obj, key);\n };\n _propertyIsEnumerable = function (obj, key) {\n return Object.prototype.propertyIsEnumerable.call(obj, key);\n };\n\n // Future traveler, although this code looks scary. It merely exists in\n // development to aid in development asertions. Production builds of\n // ember strip this entire block out\n\n handleMandatorySetter = function (m, obj, keyName) {\n var descriptor = emberUtils.lookupDescriptor(obj, keyName),\n desc;\n var hasDescriptor = descriptor !== null;\n var configurable = hasDescriptor ? descriptor.configurable : true;\n var isWritable = hasDescriptor ? descriptor.writable : true;\n var hasValue = hasDescriptor ? 'value' in descriptor : true;\n var possibleDesc = hasDescriptor && descriptor.value;\n var isDescriptor = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor;\n\n if (isDescriptor) {\n return;\n }\n\n // this x in Y deopts, so keeping it in this function is better;\n if (configurable && isWritable && hasValue && keyName in obj) {\n desc = {\n configurable: true,\n set: MANDATORY_SETTER_FUNCTION(keyName),\n enumerable: _propertyIsEnumerable(obj, keyName),\n get: undefined\n };\n\n\n if (_hasOwnProperty(obj, keyName)) {\n m.writeValues(keyName, obj[keyName]);\n desc.get = DEFAULT_GETTER_FUNCTION(keyName);\n } else {\n desc.get = INHERITING_GETTER_FUNCTION(keyName);\n }\n\n Object.defineProperty(obj, keyName, desc);\n }\n };\n }\n\n function unwatchKey(obj, keyName, _meta) {\n if (typeof obj !== 'object' || obj === null) {\n return;\n }\n var meta$$1 = _meta === undefined ? exports.peekMeta(obj) : _meta,\n possibleDesc,\n isDescriptor,\n maybeMandatoryDescriptor,\n possibleValue;\n\n // do nothing of this object has already been destroyed\n if (meta$$1 === undefined || meta$$1.isSourceDestroyed()) {\n return;\n }\n\n var count = meta$$1.peekWatching(keyName);\n if (count === 1) {\n meta$$1.writeWatching(keyName, 0);\n\n possibleDesc = obj[keyName];\n isDescriptor = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor;\n\n\n if (isDescriptor && possibleDesc.didUnwatch) {\n possibleDesc.didUnwatch(obj, keyName, meta$$1);\n }\n\n if (typeof obj.didUnwatchProperty === 'function') {\n obj.didUnwatchProperty(keyName);\n }\n\n if (ember_features.MANDATORY_SETTER) {\n // It is true, the following code looks quite WAT. But have no fear, It\n // exists purely to improve development ergonomics and is removed from\n // ember.min.js and ember.prod.js builds.\n //\n // Some further context: Once a property is watched by ember, bypassing `set`\n // for mutation, will bypass observation. This code exists to assert when\n // that occurs, and attempt to provide more helpful feedback. The alternative\n // is tricky to debug partially observable properties.\n if (!isDescriptor && keyName in obj) {\n maybeMandatoryDescriptor = emberUtils.lookupDescriptor(obj, keyName);\n\n\n if (maybeMandatoryDescriptor.set && maybeMandatoryDescriptor.set.isMandatorySetter) {\n if (maybeMandatoryDescriptor.get && maybeMandatoryDescriptor.get.isInheritingGetter) {\n possibleValue = meta$$1.readInheritedValue('values', keyName);\n\n if (possibleValue === UNDEFINED) {\n delete obj[keyName];\n return;\n }\n }\n\n Object.defineProperty(obj, keyName, {\n configurable: true,\n enumerable: Object.prototype.propertyIsEnumerable.call(obj, keyName),\n writable: true,\n value: meta$$1.peekValues(keyName)\n });\n meta$$1.deleteFromValues(keyName);\n }\n }\n }\n } else if (count > 1) {\n meta$$1.writeWatching(keyName, count - 1);\n }\n }\n\n function makeChainNode(obj) {\n return new ChainNode(null, null, obj);\n }\n\n function watchPath(obj, keyPath, meta$$1) {\n if (typeof obj !== 'object' || obj === null) {\n return;\n }\n var m = meta$$1 === undefined ? meta(obj) : meta$$1;\n var counter = m.peekWatching(keyPath) || 0;\n\n m.writeWatching(keyPath, counter + 1);\n if (counter === 0) {\n // activate watching first time\n m.writableChains(makeChainNode).add(keyPath);\n }\n }\n\n function unwatchPath(obj, keyPath, meta$$1) {\n if (typeof obj !== 'object' || obj === null) {\n return;\n }\n var m = meta$$1 === undefined ? exports.peekMeta(obj) : meta$$1;\n\n if (m === undefined) {\n return;\n }\n var counter = m.peekWatching(keyPath) || 0;\n\n if (counter === 1) {\n m.writeWatching(keyPath, 0);\n m.writableChains(makeChainNode).remove(keyPath);\n } else if (counter > 1) {\n m.writeWatching(keyPath, counter - 1);\n }\n }\n\n var FIRST_KEY = /^([^\\.]+)/;\n\n function firstKey(path) {\n return path.match(FIRST_KEY)[0];\n }\n\n function isObject(obj) {\n return typeof obj === 'object' && obj !== null;\n }\n\n function isVolatile(obj) {\n return !(isObject(obj) && obj.isDescriptor && obj._volatile === false);\n }\n\n var ChainWatchers = function () {\n function ChainWatchers() {\n\n // chain nodes that reference a key in this obj by key\n // we only create ChainWatchers when we are going to add them\n // so create this upfront\n this.chains = Object.create(null);\n }\n\n ChainWatchers.prototype.add = function (key, node) {\n var nodes = this.chains[key];\n if (nodes === undefined) {\n this.chains[key] = [node];\n } else {\n nodes.push(node);\n }\n };\n\n ChainWatchers.prototype.remove = function (key, node) {\n var nodes = this.chains[key],\n i;\n if (nodes !== undefined) {\n for (i = 0; i < nodes.length; i++) {\n if (nodes[i] === node) {\n nodes.splice(i, 1);\n break;\n }\n }\n }\n };\n\n ChainWatchers.prototype.has = function (key, node) {\n var nodes = this.chains[key],\n i;\n if (nodes !== undefined) {\n for (i = 0; i < nodes.length; i++) {\n if (nodes[i] === node) {\n return true;\n }\n }\n }\n return false;\n };\n\n ChainWatchers.prototype.revalidateAll = function () {\n for (var key in this.chains) {\n this.notify(key, true, undefined);\n }\n };\n\n ChainWatchers.prototype.revalidate = function (key) {\n this.notify(key, true, undefined);\n };\n\n // key: the string key that is part of a path changed\n // revalidate: boolean; the chains that are watching this value should revalidate\n // callback: function that will be called with the object and path that\n // will be/are invalidated by this key change, depending on\n // whether the revalidate flag is passed\n\n\n ChainWatchers.prototype.notify = function (key, revalidate, callback) {\n var nodes = this.chains[key],\n i,\n _i,\n obj,\n path;\n if (nodes === undefined || nodes.length === 0) {\n return;\n }\n\n var affected = void 0;\n\n if (callback) {\n affected = [];\n }\n\n for (i = 0; i < nodes.length; i++) {\n nodes[i].notify(revalidate, affected);\n }\n\n if (callback === undefined) {\n return;\n }\n\n // we gather callbacks so we don't notify them during revalidation\n for (_i = 0; _i < affected.length; _i += 2) {\n obj = affected[_i];\n path = affected[_i + 1];\n\n callback(obj, path);\n }\n };\n\n return ChainWatchers;\n }();\n\n function makeChainWatcher() {\n return new ChainWatchers();\n }\n\n function addChainWatcher(obj, keyName, node) {\n var m = meta(obj);\n m.writableChainWatchers(makeChainWatcher).add(keyName, node);\n watchKey(obj, keyName, m);\n }\n\n function removeChainWatcher(obj, keyName, node, _meta) {\n if (!isObject(obj)) {\n return;\n }\n\n var meta$$1 = _meta === undefined ? exports.peekMeta(obj) : _meta;\n\n if (meta$$1 === undefined || meta$$1.readableChainWatchers() === undefined) {\n return;\n }\n\n // make meta writable\n meta$$1 = meta(obj);\n\n meta$$1.readableChainWatchers().remove(keyName, node);\n\n unwatchKey(obj, keyName, meta$$1);\n }\n\n // A ChainNode watches a single key on an object. If you provide a starting\n // value for the key then the node won't actually watch it. For a root node\n // pass null for parent and key and object for value.\n\n var ChainNode = function () {\n function ChainNode(parent, key, value) {\n\n this._parent = parent;\n this._key = key;\n\n // _watching is true when calling get(this._parent, this._key) will\n // return the value of this node.\n //\n // It is false for the root of a chain (because we have no parent)\n // and for global paths (because the parent node is the object with\n // the observer on it)\n var isWatching = this._watching = value === undefined,\n obj;\n\n this._chains = undefined;\n this._object = undefined;\n this.count = 0;\n\n this._value = value;\n this._paths = undefined;\n if (isWatching) {\n obj = parent.value();\n\n\n if (!isObject(obj)) {\n return;\n }\n\n this._object = obj;\n\n addChainWatcher(this._object, this._key, this);\n }\n }\n\n ChainNode.prototype.value = function () {\n var obj;\n\n if (this._value === undefined && this._watching) {\n obj = this._parent.value();\n\n this._value = lazyGet(obj, this._key);\n }\n return this._value;\n };\n\n ChainNode.prototype.destroy = function () {\n if (this._watching) {\n removeChainWatcher(this._object, this._key, this);\n this._watching = false; // so future calls do nothing\n }\n };\n\n // copies a top level object only\n\n\n ChainNode.prototype.copy = function (obj) {\n var ret = new ChainNode(null, null, obj),\n path;\n var paths = this._paths;\n if (paths !== undefined) {\n path = void 0;\n\n for (path in paths) {\n if (paths[path] > 0) {\n ret.add(path);\n }\n }\n }\n return ret;\n };\n\n // called on the root node of a chain to setup watchers on the specified\n // path.\n\n\n ChainNode.prototype.add = function (path) {\n var paths = this._paths || (this._paths = {});\n paths[path] = (paths[path] || 0) + 1;\n\n var key = firstKey(path);\n var tail = path.slice(key.length + 1);\n\n this.chain(key, tail);\n };\n\n // called on the root node of a chain to teardown watcher on the specified\n // path\n\n\n ChainNode.prototype.remove = function (path) {\n var paths = this._paths;\n if (paths === undefined) {\n return;\n }\n if (paths[path] > 0) {\n paths[path]--;\n }\n\n var key = firstKey(path);\n var tail = path.slice(key.length + 1);\n\n this.unchain(key, tail);\n };\n\n ChainNode.prototype.chain = function (key, path) {\n var chains = this._chains;\n var node = void 0;\n if (chains === undefined) {\n chains = this._chains = Object.create(null);\n } else {\n node = chains[key];\n }\n\n if (node === undefined) {\n node = chains[key] = new ChainNode(this, key, undefined);\n }\n\n node.count++; // count chains...\n\n // chain rest of path if there is one\n if (path) {\n key = firstKey(path);\n path = path.slice(key.length + 1);\n node.chain(key, path);\n }\n };\n\n ChainNode.prototype.unchain = function (key, path) {\n var chains = this._chains,\n nextKey,\n nextPath;\n var node = chains[key];\n\n // unchain rest of path first...\n if (path && path.length > 1) {\n nextKey = firstKey(path);\n nextPath = path.slice(nextKey.length + 1);\n\n node.unchain(nextKey, nextPath);\n }\n\n // delete node if needed.\n node.count--;\n if (node.count <= 0) {\n chains[node._key] = undefined;\n node.destroy();\n }\n };\n\n ChainNode.prototype.notify = function (revalidate, affected) {\n if (revalidate && this._watching) {\n parentValue = this._parent.value();\n\n\n if (parentValue !== this._object) {\n removeChainWatcher(this._object, this._key, this);\n\n if (isObject(parentValue)) {\n this._object = parentValue;\n addChainWatcher(parentValue, this._key, this);\n } else {\n this._object = undefined;\n }\n }\n this._value = undefined;\n }\n\n // then notify chains...\n var chains = this._chains,\n parentValue,\n node;\n if (chains !== undefined) {\n node = void 0;\n\n for (var key in chains) {\n node = chains[key];\n if (node !== undefined) {\n node.notify(revalidate, affected);\n }\n }\n }\n\n if (affected && this._parent) {\n this._parent.populateAffected(this._key, 1, affected);\n }\n };\n\n ChainNode.prototype.populateAffected = function (path, depth, affected) {\n if (this._key) {\n path = this._key + '.' + path;\n }\n\n if (this._parent) {\n this._parent.populateAffected(path, depth + 1, affected);\n } else if (depth > 1) {\n affected.push(this.value(), path);\n }\n };\n\n return ChainNode;\n }();\n\n function lazyGet(obj, key) {\n if (!isObject(obj)) {\n return;\n }\n\n var meta$$1 = exports.peekMeta(obj),\n cache;\n\n // check if object meant only to be a prototype\n if (meta$$1 !== undefined && meta$$1.proto === obj) {\n return;\n }\n\n // Use `get` if the return value is an EachProxy or an uncacheable value.\n if (isVolatile(obj[key])) {\n return get(obj, key);\n // Otherwise attempt to get the cached value of the computed property\n } else {\n cache = meta$$1.readableCache();\n\n if (cache !== undefined) {\n return cacheFor.get(cache, key);\n }\n }\n }\n\n var counters = void 0;\n {\n counters = {\n peekCalls: 0,\n peekParentCalls: 0,\n peekPrototypeWalks: 0,\n setCalls: 0,\n deleteCalls: 0,\n metaCalls: 0,\n metaInstantiated: 0\n };\n }\n\n /**\n @module ember\n */\n\n var UNDEFINED = emberUtils.symbol('undefined');\n\n // FLAGS\n var SOURCE_DESTROYING = 1 << 1;\n var SOURCE_DESTROYED = 1 << 2;\n var META_DESTROYED = 1 << 3;\n var IS_PROXY = 1 << 4;\n\n var META_FIELD = '__ember_meta__';\n var NODE_STACK = [];\n\n var Meta = function () {\n function Meta(obj, parentMeta) {\n\n {\n counters.metaInstantiated++;\n }\n\n this._cache = undefined;\n this._weak = undefined;\n this._watching = undefined;\n this._mixins = undefined;\n this._bindings = undefined;\n this._values = undefined;\n this._deps = undefined;\n this._chainWatchers = undefined;\n this._chains = undefined;\n this._tag = undefined;\n this._tags = undefined;\n this._factory = undefined;\n\n // initial value for all flags right now is false\n // see FLAGS const for detailed list of flags used\n this._flags = 0;\n\n // used only internally\n this.source = obj;\n\n // when meta(obj).proto === obj, the object is intended to be only a\n // prototype and doesn't need to actually be observable itself\n this.proto = undefined;\n\n // The next meta in our inheritance chain. We (will) track this\n // explicitly instead of using prototypical inheritance because we\n // have detailed knowledge of how each property should really be\n // inherited, and we can optimize it much better than JS runtimes.\n this.parent = parentMeta;\n\n this._listeners = undefined;\n this._listenersFinalized = false;\n this._suspendedListeners = undefined;\n }\n\n Meta.prototype.isInitialized = function (obj) {\n return this.proto !== obj;\n };\n\n Meta.prototype.destroy = function () {\n if (this.isMetaDestroyed()) {\n return;\n }\n\n // remove chainWatchers to remove circular references that would prevent GC\n var nodes = void 0,\n key = void 0,\n nodeObject = void 0,\n foreignMeta;\n var node = this.readableChains();\n if (node !== undefined) {\n NODE_STACK.push(node);\n // process tree\n while (NODE_STACK.length > 0) {\n node = NODE_STACK.pop();\n // push children\n nodes = node._chains;\n if (nodes !== undefined) {\n for (key in nodes) {\n if (nodes[key] !== undefined) {\n NODE_STACK.push(nodes[key]);\n }\n }\n }\n\n // remove chainWatcher in node object\n if (node._watching) {\n nodeObject = node._object;\n if (nodeObject !== undefined) {\n foreignMeta = exports.peekMeta(nodeObject);\n // avoid cleaning up chain watchers when both current and\n // foreign objects are being destroyed\n // if both are being destroyed manual cleanup is not needed\n // as they will be GC'ed and no non-destroyed references will\n // be remaining\n\n if (foreignMeta && !foreignMeta.isSourceDestroying()) {\n removeChainWatcher(nodeObject, node._key, node, foreignMeta);\n }\n }\n }\n }\n }\n\n this.setMetaDestroyed();\n };\n\n Meta.prototype.isSourceDestroying = function () {\n return (this._flags & SOURCE_DESTROYING) !== 0;\n };\n\n Meta.prototype.setSourceDestroying = function () {\n this._flags |= SOURCE_DESTROYING;\n };\n\n Meta.prototype.isSourceDestroyed = function () {\n return (this._flags & SOURCE_DESTROYED) !== 0;\n };\n\n Meta.prototype.setSourceDestroyed = function () {\n this._flags |= SOURCE_DESTROYED;\n };\n\n Meta.prototype.isMetaDestroyed = function () {\n return (this._flags & META_DESTROYED) !== 0;\n };\n\n Meta.prototype.setMetaDestroyed = function () {\n this._flags |= META_DESTROYED;\n };\n\n Meta.prototype.isProxy = function () {\n return (this._flags & IS_PROXY) !== 0;\n };\n\n Meta.prototype.setProxy = function () {\n this._flags |= IS_PROXY;\n };\n\n Meta.prototype._getOrCreateOwnMap = function (key) {\n return this[key] || (this[key] = Object.create(null));\n };\n\n Meta.prototype._getInherited = function (key) {\n var pointer = this,\n map;\n while (pointer !== undefined) {\n map = pointer[key];\n\n if (map !== undefined) {\n return map;\n }\n pointer = pointer.parent;\n }\n };\n\n Meta.prototype._findInherited = function (key, subkey) {\n var pointer = this,\n map,\n value;\n while (pointer !== undefined) {\n map = pointer[key];\n\n if (map !== undefined) {\n value = map[subkey];\n\n if (value !== undefined) {\n return value;\n }\n }\n pointer = pointer.parent;\n }\n };\n\n // Implements a member that provides a lazily created map of maps,\n // with inheritance at both levels.\n\n\n Meta.prototype.writeDeps = function (subkey, itemkey, value) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot modify dependent keys for `' + itemkey + '` on `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n var outerMap = this._getOrCreateOwnMap('_deps');\n var innerMap = outerMap[subkey];\n if (innerMap === undefined) {\n innerMap = outerMap[subkey] = Object.create(null);\n }\n innerMap[itemkey] = value;\n };\n\n Meta.prototype.peekDeps = function (subkey, itemkey) {\n var pointer = this,\n map,\n value,\n itemvalue;\n while (pointer !== undefined) {\n map = pointer._deps;\n\n if (map !== undefined) {\n value = map[subkey];\n\n if (value !== undefined) {\n itemvalue = value[itemkey];\n\n if (itemvalue !== undefined) {\n return itemvalue;\n }\n }\n }\n pointer = pointer.parent;\n }\n };\n\n Meta.prototype.hasDeps = function (subkey) {\n var pointer = this,\n deps;\n while (pointer !== undefined) {\n deps = pointer._deps;\n\n if (deps !== undefined && deps[subkey] !== undefined) {\n return true;\n }\n pointer = pointer.parent;\n }\n return false;\n };\n\n Meta.prototype.forEachInDeps = function (subkey, fn) {\n return this._forEachIn('_deps', subkey, fn);\n };\n\n Meta.prototype._forEachIn = function (key, subkey, fn) {\n var pointer = this,\n map,\n innerMap,\n i;\n var seen = void 0;\n var calls = void 0;\n while (pointer !== undefined) {\n map = pointer[key];\n\n if (map !== undefined) {\n innerMap = map[subkey];\n\n if (innerMap !== undefined) {\n for (var innerKey in innerMap) {\n seen = seen || Object.create(null);\n if (seen[innerKey] === undefined) {\n seen[innerKey] = true;\n calls = calls || [];\n calls.push(innerKey, innerMap[innerKey]);\n }\n }\n }\n }\n pointer = pointer.parent;\n }\n\n if (calls !== undefined) {\n for (i = 0; i < calls.length; i += 2) {\n fn(calls[i], calls[i + 1]);\n }\n }\n };\n\n Meta.prototype.writableCache = function () {\n return this._getOrCreateOwnMap('_cache');\n };\n\n Meta.prototype.readableCache = function () {\n return this._cache;\n };\n\n Meta.prototype.writableWeak = function () {\n return this._getOrCreateOwnMap('_weak');\n };\n\n Meta.prototype.readableWeak = function () {\n return this._weak;\n };\n\n Meta.prototype.writableTags = function () {\n return this._getOrCreateOwnMap('_tags');\n };\n\n Meta.prototype.readableTags = function () {\n return this._tags;\n };\n\n Meta.prototype.writableTag = function (create) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot create a new tag for `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n var ret = this._tag;\n if (ret === undefined) {\n ret = this._tag = create(this.source);\n }\n return ret;\n };\n\n Meta.prototype.readableTag = function () {\n return this._tag;\n };\n\n Meta.prototype.writableChainWatchers = function (create) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot create a new chain watcher for `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n var ret = this._chainWatchers;\n if (ret === undefined) {\n ret = this._chainWatchers = create(this.source);\n }\n return ret;\n };\n\n Meta.prototype.readableChainWatchers = function () {\n return this._chainWatchers;\n };\n\n Meta.prototype.writableChains = function (create) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot create a new chains for `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n var ret = this._chains;\n if (ret === undefined) {\n if (this.parent === undefined) {\n ret = create(this.source);\n } else {\n ret = this.parent.writableChains(create).copy(this.source);\n }\n this._chains = ret;\n }\n return ret;\n };\n\n Meta.prototype.readableChains = function () {\n return this._getInherited('_chains');\n };\n\n Meta.prototype.writeWatching = function (subkey, value) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot update watchers for `' + subkey + '` on `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n var map = this._getOrCreateOwnMap('_watching');\n map[subkey] = value;\n };\n\n Meta.prototype.peekWatching = function (subkey) {\n return this._findInherited('_watching', subkey);\n };\n\n Meta.prototype.writeMixins = function (subkey, value) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot add mixins for `' + subkey + '` on `' + emberUtils.toString(this.source) + '` call writeMixins after it has been destroyed.', !this.isMetaDestroyed());\n\n var map = this._getOrCreateOwnMap('_mixins');\n map[subkey] = value;\n };\n\n Meta.prototype.peekMixins = function (subkey) {\n return this._findInherited('_mixins', subkey);\n };\n\n Meta.prototype.forEachMixins = function (fn) {\n var pointer = this,\n map;\n var seen = void 0;\n while (pointer !== undefined) {\n map = pointer._mixins;\n\n if (map !== undefined) {\n for (var key in map) {\n seen = seen || Object.create(null);\n if (seen[key] === undefined) {\n seen[key] = true;\n fn(key, map[key]);\n }\n }\n }\n pointer = pointer.parent;\n }\n };\n\n Meta.prototype.writeBindings = function (subkey, value) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot add a binding for `' + subkey + '` on `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n var map = this._getOrCreateOwnMap('_bindings');\n map[subkey] = value;\n };\n\n Meta.prototype.peekBindings = function (subkey) {\n return this._findInherited('_bindings', subkey);\n };\n\n Meta.prototype.forEachBindings = function (fn) {\n var pointer = this,\n map;\n var seen = void 0;\n while (pointer !== undefined) {\n map = pointer._bindings;\n\n if (map !== undefined) {\n for (var key in map) {\n seen = seen || Object.create(null);\n if (seen[key] === undefined) {\n seen[key] = true;\n fn(key, map[key]);\n }\n }\n }\n pointer = pointer.parent;\n }\n };\n\n Meta.prototype.clearBindings = function () {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot clear bindings on `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n this._bindings = undefined;\n };\n\n Meta.prototype.writeValues = function (subkey, value) {\n true && !!this.isMetaDestroyed() && emberDebug.assert('Cannot set the value of `' + subkey + '` on `' + emberUtils.toString(this.source) + '` after it has been destroyed.', !this.isMetaDestroyed());\n\n var map = this._getOrCreateOwnMap('_values');\n map[subkey] = value;\n };\n\n Meta.prototype.peekValues = function (subkey) {\n return this._findInherited('_values', subkey);\n };\n\n Meta.prototype.deleteFromValues = function (subkey) {\n delete this._getOrCreateOwnMap('_values')[subkey];\n };\n\n emberBabel.createClass(Meta, [{\n key: 'factory',\n set: function (factory) {\n this._factory = factory;\n },\n get: function () {\n return this._factory;\n }\n }]);\n\n return Meta;\n }();\n\n for (var name in protoMethods) {\n Meta.prototype[name] = protoMethods[name];\n }\n\n var META_DESC = {\n writable: true,\n configurable: true,\n enumerable: false,\n value: null\n };\n\n var EMBER_META_PROPERTY = {\n name: META_FIELD,\n descriptor: META_DESC\n };\n\n if (ember_features.MANDATORY_SETTER) {\n Meta.prototype.readInheritedValue = function (key, subkey) {\n\n var pointer = this,\n map,\n value;\n\n while (pointer !== undefined) {\n map = pointer['_' + key];\n\n if (map !== undefined) {\n value = map[subkey];\n\n if (value !== undefined || subkey in map) {\n return value;\n }\n }\n pointer = pointer.parent;\n }\n\n return UNDEFINED;\n };\n\n Meta.prototype.writeValue = function (obj, key, value) {\n var descriptor = emberUtils.lookupDescriptor(obj, key);\n var isMandatorySetter = descriptor !== null && descriptor.set && descriptor.set.isMandatorySetter;\n\n if (isMandatorySetter) {\n this.writeValues(key, value);\n } else {\n obj[key] = value;\n }\n };\n }\n\n var setMeta = void 0;\n exports.peekMeta = void 0;\n\n // choose the one appropriate for given platform\n if (emberUtils.HAS_NATIVE_WEAKMAP) {\n getPrototypeOf = Object.getPrototypeOf;\n metaStore = new WeakMap();\n\n\n setMeta = function (obj, meta) {\n {\n counters.setCalls++;\n }\n metaStore.set(obj, meta);\n };\n\n exports.peekMeta = function (obj) {\n var pointer = obj;\n var meta = void 0;\n while (pointer !== undefined && pointer !== null) {\n meta = metaStore.get(pointer);\n // jshint loopfunc:true\n {\n counters.peekCalls++;\n }\n if (meta !== undefined) {\n return meta;\n }\n\n pointer = getPrototypeOf(pointer);\n {\n counters.peekPrototypeWalks++;\n }\n }\n };\n } else {\n setMeta = function (obj, meta) {\n if (obj.__defineNonEnumerable) {\n obj.__defineNonEnumerable(EMBER_META_PROPERTY);\n } else {\n Object.defineProperty(obj, META_FIELD, META_DESC);\n }\n\n obj[META_FIELD] = meta;\n };\n\n exports.peekMeta = function (obj) {\n return obj[META_FIELD];\n };\n }\n\n /**\n Tears down the meta on an object so that it can be garbage collected.\n Multiple calls will have no effect.\n \n @method deleteMeta\n @for Ember\n @param {Object} obj the object to destroy\n @return {void}\n @private\n */\n\n\n /**\n Retrieves the meta hash for an object. If `writable` is true ensures the\n hash is writable for this object as well.\n \n The meta object contains information about computed property descriptors as\n well as any watched properties and other information. You generally will\n not access this information directly but instead work with higher level\n methods that manipulate this hash indirectly.\n \n @method meta\n @for Ember\n @private\n \n @param {Object} obj The object to retrieve meta for\n @param {Boolean} [writable=true] Pass `false` if you do not intend to modify\n the meta hash, allowing the method to avoid making an unnecessary copy.\n @return {Object} the meta hash for an object\n */\n function meta(obj) {\n {\n counters.metaCalls++;\n }\n\n var maybeMeta = exports.peekMeta(obj);\n var parent = void 0;\n\n // remove this code, in-favor of explicit parent\n if (maybeMeta !== undefined) {\n if (maybeMeta.source === obj) {\n return maybeMeta;\n }\n parent = maybeMeta;\n }\n\n var newMeta = new Meta(obj, parent);\n setMeta(obj, newMeta);\n return newMeta;\n }\n\n var Cache = function () {\n function Cache(limit, func, key, store) {\n\n this.size = 0;\n this.misses = 0;\n this.hits = 0;\n this.limit = limit;\n this.func = func;\n this.key = key;\n this.store = store || new DefaultStore();\n }\n\n Cache.prototype.get = function (obj) {\n var key = this.key === undefined ? obj : this.key(obj);\n var value = this.store.get(key);\n if (value === undefined) {\n this.misses++;\n value = this._set(key, this.func(obj));\n } else if (value === UNDEFINED) {\n this.hits++;\n value = undefined;\n } else {\n this.hits++;\n // nothing to translate\n }\n\n return value;\n };\n\n Cache.prototype.set = function (obj, value) {\n var key = this.key === undefined ? obj : this.key(obj);\n return this._set(key, value);\n };\n\n Cache.prototype._set = function (key, value) {\n if (this.limit > this.size) {\n this.size++;\n if (value === undefined) {\n this.store.set(key, UNDEFINED);\n } else {\n this.store.set(key, value);\n }\n }\n\n return value;\n };\n\n Cache.prototype.purge = function () {\n this.store.clear();\n this.size = 0;\n this.hits = 0;\n this.misses = 0;\n };\n\n return Cache;\n }();\n\n var DefaultStore = function () {\n function DefaultStore() {\n\n this.data = Object.create(null);\n }\n\n DefaultStore.prototype.get = function (key) {\n return this.data[key];\n };\n\n DefaultStore.prototype.set = function (key, value) {\n this.data[key] = value;\n };\n\n DefaultStore.prototype.clear = function () {\n this.data = Object.create(null);\n };\n\n return DefaultStore;\n }();\n\n var IS_GLOBAL_PATH = /^[A-Z$].*[\\.]/;\n\n var isGlobalPathCache = new Cache(1000, function (key) {\n return IS_GLOBAL_PATH.test(key);\n });\n var firstDotIndexCache = new Cache(1000, function (key) {\n return key.indexOf('.');\n });\n\n var firstKeyCache = new Cache(1000, function (path) {\n var index = firstDotIndexCache.get(path);\n return index === -1 ? path : path.slice(0, index);\n });\n\n var tailPathCache = new Cache(1000, function (path) {\n var index = firstDotIndexCache.get(path);\n return index === -1 ? undefined : path.slice(index + 1);\n });\n\n function isGlobalPath(path) {\n return isGlobalPathCache.get(path);\n }\n\n function isPath(path) {\n return firstDotIndexCache.get(path) !== -1;\n }\n\n function getFirstKey(path) {\n return firstKeyCache.get(path);\n }\n\n function getTailPath(path) {\n return tailPathCache.get(path);\n }\n\n /**\n @module @ember/object\n */\n\n var ALLOWABLE_TYPES = {\n object: true,\n function: true,\n string: true\n };\n\n // ..........................................................\n // GET AND SET\n //\n // If we are on a platform that supports accessors we can use those.\n // Otherwise simulate accessors by looking up the property directly on the\n // object.\n\n /**\n Gets the value of a property on an object. If the property is computed,\n the function will be invoked. If the property is not defined but the\n object implements the `unknownProperty` method then that will be invoked.\n \n ```javascript\n Ember.get(obj, \"name\");\n ```\n \n If you plan to run on IE8 and older browsers then you should use this\n method anytime you want to retrieve a property on an object that you don't\n know for sure is private. (Properties beginning with an underscore '_'\n are considered private.)\n \n On all newer browsers, you only need to use this method to retrieve\n properties if the property might not be defined on the object and you want\n to respect the `unknownProperty` handler. Otherwise you can ignore this\n method.\n \n Note that if the object itself is `undefined`, this method will throw\n an error.\n \n @method get\n @for @ember/object\n @static\n @param {Object} obj The object to retrieve from.\n @param {String} keyName The property key to retrieve\n @return {Object} the property value or `null`.\n @public\n */\n function get(obj, keyName) {\n true && !(arguments.length === 2) && emberDebug.assert('Get must be called with two arguments; an object and a property key', arguments.length === 2);\n true && !(obj !== undefined && obj !== null) && emberDebug.assert('Cannot call get with \\'' + keyName + '\\' on an undefined object.', obj !== undefined && obj !== null);\n true && !(typeof keyName === 'string') && emberDebug.assert('The key provided to get must be a string, you passed ' + keyName, typeof keyName === 'string');\n true && !(keyName.lastIndexOf('this.', 0) !== 0) && emberDebug.assert('\\'this\\' in paths is not supported', keyName.lastIndexOf('this.', 0) !== 0);\n true && !(keyName !== '') && emberDebug.assert('Cannot call `Ember.get` with an empty string', keyName !== '');\n\n var value = obj[keyName];\n var isDescriptor = value !== null && typeof value === 'object' && value.isDescriptor;\n\n if (isDescriptor) {\n return value.get(obj, keyName);\n } else if (isPath(keyName)) {\n return _getPath(obj, keyName);\n } else if (value === undefined && 'object' === typeof obj && !(keyName in obj) && typeof obj.unknownProperty === 'function') {\n return obj.unknownProperty(keyName);\n } else {\n return value;\n }\n }\n\n function _getPath(root, path) {\n var obj = root,\n i;\n var parts = path.split('.');\n\n for (i = 0; i < parts.length; i++) {\n if (!isGettable(obj)) {\n return undefined;\n }\n\n obj = get(obj, parts[i]);\n\n if (obj && obj.isDestroyed) {\n return undefined;\n }\n }\n\n return obj;\n }\n\n function isGettable(obj) {\n return obj !== undefined && obj !== null && ALLOWABLE_TYPES[typeof obj];\n }\n\n /**\n Retrieves the value of a property from an Object, or a default value in the\n case that the property returns `undefined`.\n \n ```javascript\n Ember.getWithDefault(person, 'lastName', 'Doe');\n ```\n \n @method getWithDefault\n @for @ember/object\n @static\n @param {Object} obj The object to retrieve from.\n @param {String} keyName The name of the property to retrieve\n @param {Object} defaultValue The value to return if the property value is undefined\n @return {Object} The property value or the defaultValue.\n @public\n */\n\n\n /**\n @module @ember/object\n */\n /**\n Sets the value of a property on an object, respecting computed properties\n and notifying observers and other listeners of the change. If the\n property is not defined but the object implements the `setUnknownProperty`\n method then that will be invoked as well.\n \n ```javascript\n Ember.set(obj, \"name\", value);\n ```\n \n @method set\n @static\n @for @ember/object\n @param {Object} obj The object to modify.\n @param {String} keyName The property key to set\n @param {Object} value The value to set\n @return {Object} the passed value.\n @public\n */\n function set(obj, keyName, value, tolerant) {\n true && !(arguments.length === 3 || arguments.length === 4) && emberDebug.assert('Set must be called with three or four arguments; an object, a property key, a value and tolerant true/false', arguments.length === 3 || arguments.length === 4);\n true && !(obj && typeof obj === 'object' || typeof obj === 'function') && emberDebug.assert('Cannot call set with \\'' + keyName + '\\' on an undefined object.', obj && typeof obj === 'object' || typeof obj === 'function');\n true && !(typeof keyName === 'string') && emberDebug.assert('The key provided to set must be a string, you passed ' + keyName, typeof keyName === 'string');\n true && !(keyName.lastIndexOf('this.', 0) !== 0) && emberDebug.assert('\\'this\\' in paths is not supported', keyName.lastIndexOf('this.', 0) !== 0);\n true && !!obj.isDestroyed && emberDebug.assert('calling set on destroyed object: ' + emberUtils.toString(obj) + '.' + keyName + ' = ' + emberUtils.toString(value), !obj.isDestroyed);\n\n if (isPath(keyName)) {\n return setPath(obj, keyName, value, tolerant);\n }\n\n var currentValue = obj[keyName],\n meta$$1;\n var isDescriptor = currentValue !== null && typeof currentValue === 'object' && currentValue.isDescriptor;\n\n if (isDescriptor) {\n /* computed property */\n currentValue.set(obj, keyName, value);\n } else if (currentValue === undefined && 'object' === typeof obj && !(keyName in obj) && typeof obj.setUnknownProperty === 'function') {\n /* unknown property */\n obj.setUnknownProperty(keyName, value);\n } else if (!(currentValue === value)) {\n meta$$1 = exports.peekMeta(obj);\n\n propertyWillChange(obj, keyName, meta$$1);\n\n if (ember_features.MANDATORY_SETTER) {\n setWithMandatorySetter(meta$$1, obj, keyName, value);\n } else {\n obj[keyName] = value;\n }\n\n propertyDidChange(obj, keyName, meta$$1);\n }\n\n return value;\n }\n\n if (ember_features.MANDATORY_SETTER) {\n setWithMandatorySetter = function (meta$$1, obj, keyName, value) {\n if (meta$$1 !== undefined && meta$$1.peekWatching(keyName) > 0) {\n makeEnumerable(obj, keyName);\n meta$$1.writeValue(obj, keyName, value);\n } else {\n obj[keyName] = value;\n }\n };\n makeEnumerable = function (obj, key) {\n var desc = Object.getOwnPropertyDescriptor(obj, key);\n\n if (desc && desc.set && desc.set.isMandatorySetter) {\n desc.enumerable = true;\n Object.defineProperty(obj, key, desc);\n }\n };\n }\n\n function setPath(root, path, value, tolerant) {\n var parts = path.split('.');\n var keyName = parts.pop();\n\n true && !(keyName.trim().length > 0) && emberDebug.assert('Property set failed: You passed an empty path', keyName.trim().length > 0);\n\n var newPath = parts.join('.');\n\n var newRoot = _getPath(root, newPath);\n\n if (newRoot) {\n return set(newRoot, keyName, value);\n } else if (!tolerant) {\n throw new emberDebug.Error('Property set failed: object in path \"' + newPath + '\" could not be found or was destroyed.');\n }\n }\n\n /**\n Error-tolerant form of `Ember.set`. Will not blow up if any part of the\n chain is `undefined`, `null`, or destroyed.\n \n This is primarily used when syncing bindings, which may try to update after\n an object has been destroyed.\n \n @method trySet\n @static\n @for @ember/object\n @param {Object} root The object to modify.\n @param {String} path The property path to set\n @param {Object} value The value to set\n @public\n */\n function trySet(root, path, value) {\n return set(root, path, value, true);\n }\n\n /**\n @module @ember/object\n */\n\n var END_WITH_EACH_REGEX = /\\.@each$/;\n\n /**\n Expands `pattern`, invoking `callback` for each expansion.\n \n The only pattern supported is brace-expansion, anything else will be passed\n once to `callback` directly.\n \n Example\n \n ```js\n import { expandProperties } from '@ember/object/computed';\n \n function echo(arg){ console.log(arg); }\n \n expandProperties('foo.bar', echo); //=> 'foo.bar'\n expandProperties('{foo,bar}', echo); //=> 'foo', 'bar'\n expandProperties('foo.{bar,baz}', echo); //=> 'foo.bar', 'foo.baz'\n expandProperties('{foo,bar}.baz', echo); //=> 'foo.baz', 'bar.baz'\n expandProperties('foo.{bar,baz}.[]', echo) //=> 'foo.bar.[]', 'foo.baz.[]'\n expandProperties('{foo,bar}.{spam,eggs}', echo) //=> 'foo.spam', 'foo.eggs', 'bar.spam', 'bar.eggs'\n expandProperties('{foo}.bar.{baz}') //=> 'foo.bar.baz'\n ```\n \n @method expandProperties\n @static\n @for @ember/object\n @public\n @param {String} pattern The property pattern to expand.\n @param {Function} callback The callback to invoke. It is invoked once per\n expansion, and is passed the expansion.\n */\n function expandProperties(pattern, callback) {\n true && !(typeof pattern === 'string') && emberDebug.assert('A computed property key must be a string, you passed ' + typeof pattern + ' ' + pattern, typeof pattern === 'string');\n true && !(pattern.indexOf(' ') === -1) && emberDebug.assert('Brace expanded properties cannot contain spaces, e.g. \"user.{firstName, lastName}\" should be \"user.{firstName,lastName}\"', pattern.indexOf(' ') === -1);\n // regex to look for double open, double close, or unclosed braces\n\n true && !(pattern.match(/\\{[^}{]*\\{|\\}[^}{]*\\}|\\{[^}]*$/g) === null) && emberDebug.assert('Brace expanded properties have to be balanced and cannot be nested, pattern: ' + pattern, pattern.match(/\\{[^}{]*\\{|\\}[^}{]*\\}|\\{[^}]*$/g) === null);\n\n var start = pattern.indexOf('{');\n if (start < 0) {\n callback(pattern.replace(END_WITH_EACH_REGEX, '.[]'));\n } else {\n dive('', pattern, start, callback);\n }\n }\n\n function dive(prefix, pattern, start, callback) {\n var end = pattern.indexOf('}'),\n i = 0,\n newStart = void 0,\n arrayLength = void 0;\n var tempArr = pattern.substring(start + 1, end).split(',');\n var after = pattern.substring(end + 1);\n prefix = prefix + pattern.substring(0, start);\n\n arrayLength = tempArr.length;\n while (i < arrayLength) {\n newStart = after.indexOf('{');\n if (newStart < 0) {\n callback((prefix + tempArr[i++] + after).replace(END_WITH_EACH_REGEX, '.[]'));\n } else {\n dive(prefix + tempArr[i++], after, newStart, callback);\n }\n }\n }\n\n /**\n @module ember\n */\n /**\n Starts watching a property on an object. Whenever the property changes,\n invokes `Ember.propertyWillChange` and `Ember.propertyDidChange`. This is the\n primitive used by observers and dependent keys; usually you will never call\n this method directly but instead use higher level methods like\n `Ember.addObserver()`\n \n @private\n @method watch\n @for Ember\n @param obj\n @param {String} _keyPath\n */\n function watch(obj, _keyPath, m) {\n if (isPath(_keyPath)) {\n watchPath(obj, _keyPath, m);\n } else {\n watchKey(obj, _keyPath, m);\n }\n }\n\n function watcherCount(obj, key) {\n var meta$$1 = exports.peekMeta(obj);\n return meta$$1 !== undefined && meta$$1.peekWatching(key) || 0;\n }\n\n function unwatch(obj, _keyPath, m) {\n if (isPath(_keyPath)) {\n unwatchPath(obj, _keyPath, m);\n } else {\n unwatchKey(obj, _keyPath, m);\n }\n }\n\n // ..........................................................\n // DEPENDENT KEYS\n //\n\n function addDependentKeys(desc, obj, keyName, meta) {\n // the descriptor has a list of dependent keys, so\n // add all of its dependent keys.\n var depKeys = desc._dependentKeys,\n idx,\n depKey;\n if (depKeys === null || depKeys === undefined) {\n return;\n }\n\n for (idx = 0; idx < depKeys.length; idx++) {\n depKey = depKeys[idx];\n // Increment the number of times depKey depends on keyName.\n\n meta.writeDeps(depKey, keyName, (meta.peekDeps(depKey, keyName) || 0) + 1);\n // Watch the depKey\n watch(obj, depKey, meta);\n }\n }\n\n function removeDependentKeys(desc, obj, keyName, meta) {\n // the descriptor has a list of dependent keys, so\n // remove all of its dependent keys.\n var depKeys = desc._dependentKeys,\n idx,\n depKey;\n if (depKeys === null || depKeys === undefined) {\n return;\n }\n\n for (idx = 0; idx < depKeys.length; idx++) {\n depKey = depKeys[idx];\n // Decrement the number of times depKey depends on keyName.\n\n meta.writeDeps(depKey, keyName, (meta.peekDeps(depKey, keyName) || 0) - 1);\n // Unwatch the depKey\n unwatch(obj, depKey, meta);\n }\n }\n\n /**\n @module @ember/object\n */\n\n var DEEP_EACH_REGEX = /\\.@each\\.[^.]+\\./;\n\n /**\n A computed property transforms an object literal with object's accessor function(s) into a property.\n \n By default the function backing the computed property will only be called\n once and the result will be cached. You can specify various properties\n that your computed property depends on. This will force the cached\n result to be recomputed if the dependencies are modified.\n \n In the following example we declare a computed property - `fullName` - by calling\n `computed` with property dependencies (`firstName` and `lastName`) as leading arguments and getter accessor function. The `fullName` getter function\n will be called once (regardless of how many times it is accessed) as long\n as its dependencies have not changed. Once `firstName` or `lastName` are updated\n any future calls (or anything bound) to `fullName` will incorporate the new\n values.\n \n ```javascript\n import EmberObject, { computed } from '@ember/object';\n \n let Person = EmberObject.extend({\n // these will be supplied by `create`\n firstName: null,\n lastName: null,\n \n fullName: computed('firstName', 'lastName', function() {\n let firstName = this.get('firstName'),\n lastName = this.get('lastName');\n \n return `${firstName} ${lastName}`;\n })\n });\n \n let tom = Person.create({\n firstName: 'Tom',\n lastName: 'Dale'\n });\n \n tom.get('fullName') // 'Tom Dale'\n ```\n \n You can also define what Ember should do when setting a computed property by providing additional function (`set`) in hash argument.\n If you try to set a computed property, it will try to invoke setter accessor function with the key and\n value you want to set it to as arguments.\n \n ```javascript\n import EmberObject, { computed } from '@ember/object';\n \n let Person = EmberObject.extend({\n // these will be supplied by `create`\n firstName: null,\n lastName: null,\n \n fullName: computed('firstName', 'lastName', {\n get(key) {\n let firstName = this.get('firstName'),\n lastName = this.get('lastName');\n \n return firstName + ' ' + lastName;\n },\n set(key, value) {\n let [firstName, lastName] = value.split(' ');\n \n this.set('firstName', firstName);\n this.set('lastName', lastName);\n \n return value;\n }\n })\n });\n \n let person = Person.create();\n \n person.set('fullName', 'Peter Wagenet');\n person.get('firstName'); // 'Peter'\n person.get('lastName'); // 'Wagenet'\n ```\n \n You can overwrite computed property with normal property (no longer computed), that won't change if dependencies change, if you set computed property and it won't have setter accessor function defined.\n \n You can also mark computed property as `.readOnly()` and block all attempts to set it.\n \n ```javascript\n import EmberObject, { computed } from '@ember/object';\n \n let Person = EmberObject.extend({\n // these will be supplied by `create`\n firstName: null,\n lastName: null,\n \n fullName: computed('firstName', 'lastName', {\n get(key) {\n let firstName = this.get('firstName');\n let lastName = this.get('lastName');\n \n return firstName + ' ' + lastName;\n }\n }).readOnly()\n });\n \n let person = Person.create();\n person.set('fullName', 'Peter Wagenet'); // Uncaught Error: Cannot set read-only property \"fullName\" on object: <(...):emberXXX>\n ```\n \n Additional resources:\n - [New CP syntax RFC](https://github.com/emberjs/rfcs/blob/master/text/0011-improved-cp-syntax.md)\n - [New computed syntax explained in \"Ember 1.12 released\" ](https://emberjs.com/blog/2015/05/13/ember-1-12-released.html#toc_new-computed-syntax)\n \n @class ComputedProperty\n @public\n */\n function ComputedProperty(config, opts) {\n this.isDescriptor = true;\n var hasGetterOnly = typeof config === 'function';\n if (hasGetterOnly) {\n this._getter = config;\n } else {\n true && !(typeof config === 'object' && !Array.isArray(config)) && emberDebug.assert('computed expects a function or an object as last argument.', typeof config === 'object' && !Array.isArray(config));\n true && !Object.keys(config).every(function (key) {\n return key === 'get' || key === 'set';\n }) && emberDebug.assert('Config object passed to computed can only contain `get` or `set` keys.', Object.keys(config).every(function (key) {\n return key === 'get' || key === 'set';\n }));\n\n this._getter = config.get;\n this._setter = config.set;\n }\n true && !(!!this._getter || !!this._setter) && emberDebug.assert('Computed properties must receive a getter or a setter, you passed none.', !!this._getter || !!this._setter);\n\n this._suspended = undefined;\n this._meta = undefined;\n this._volatile = false;\n\n this._dependentKeys = opts && opts.dependentKeys;\n this._readOnly = opts && hasGetterOnly && opts.readOnly === true;\n }\n\n ComputedProperty.prototype = new Descriptor();\n ComputedProperty.prototype.constructor = ComputedProperty;\n\n var ComputedPropertyPrototype = ComputedProperty.prototype;\n\n /**\n Call on a computed property to set it into non-cached mode. When in this\n mode the computed property will not automatically cache the return value.\n \n It also does not automatically fire any change events. You must manually notify\n any changes if you want to observe this property.\n \n Dependency keys have no effect on volatile properties as they are for cache\n invalidation and notification when cached value is invalidated.\n \n ```javascript\n import EmberObject, { computed } from '@ember/object';\n \n let outsideService = EmberObject.extend({\n value: computed(function() {\n return OutsideService.getValue();\n }).volatile()\n }).create();\n ```\n \n @method volatile\n @return {ComputedProperty} this\n @chainable\n @public\n */\n ComputedPropertyPrototype.volatile = function () {\n this._volatile = true;\n return this;\n };\n\n /**\n Call on a computed property to set it into read-only mode. When in this\n mode the computed property will throw an error when set.\n \n ```javascript\n import EmberObject, { computed } from '@ember/object';\n \n let Person = EmberObject.extend({\n guid: computed(function() {\n return 'guid-guid-guid';\n }).readOnly()\n });\n \n let person = Person.create();\n \n person.set('guid', 'new-guid'); // will throw an exception\n ```\n \n @method readOnly\n @return {ComputedProperty} this\n @chainable\n @public\n */\n ComputedPropertyPrototype.readOnly = function () {\n this._readOnly = true;\n true && !!(this._readOnly && this._setter && this._setter !== this._getter) && emberDebug.assert('Computed properties that define a setter using the new syntax cannot be read-only', !(this._readOnly && this._setter && this._setter !== this._getter));\n\n return this;\n };\n\n /**\n Sets the dependent keys on this computed property. Pass any number of\n arguments containing key paths that this computed property depends on.\n \n ```javascript\n import EmberObject, { computed } from '@ember/object';\n \n let President = EmberObject.extend({\n fullName: computed('firstName', 'lastName', function() {\n return this.get('firstName') + ' ' + this.get('lastName');\n \n // Tell Ember that this computed property depends on firstName\n // and lastName\n })\n });\n \n let president = President.create({\n firstName: 'Barack',\n lastName: 'Obama'\n });\n \n president.get('fullName'); // 'Barack Obama'\n ```\n \n @method property\n @param {String} path* zero or more property paths\n @return {ComputedProperty} this\n @chainable\n @public\n */\n ComputedPropertyPrototype.property = function () {\n var args = [],\n i;\n\n function addArg(property) {\n true && emberDebug.warn('Dependent keys containing @each only work one level deep. ' + ('You used the key \"' + property + '\" which is invalid. ') + 'Please create an intermediary computed property.', DEEP_EACH_REGEX.test(property) === false, { id: 'ember-metal.computed-deep-each' });\n\n args.push(property);\n }\n\n for (i = 0; i < arguments.length; i++) {\n expandProperties(arguments[i], addArg);\n }\n\n this._dependentKeys = args;\n return this;\n };\n\n /**\n In some cases, you may want to annotate computed properties with additional\n metadata about how they function or what values they operate on. For example,\n computed property functions may close over variables that are then no longer\n available for introspection.\n \n You can pass a hash of these values to a computed property like this:\n \n ```\n import { computed } from '@ember/object';\n import Person from 'my-app/utils/person';\n \n person: computed(function() {\n let personId = this.get('personId');\n return Person.create({ id: personId });\n }).meta({ type: Person })\n ```\n \n The hash that you pass to the `meta()` function will be saved on the\n computed property descriptor under the `_meta` key. Ember runtime\n exposes a public API for retrieving these values from classes,\n via the `metaForProperty()` function.\n \n @method meta\n @param {Object} meta\n @chainable\n @public\n */\n ComputedPropertyPrototype.meta = function (meta$$1) {\n if (arguments.length === 0) {\n return this._meta || {};\n } else {\n this._meta = meta$$1;\n return this;\n }\n };\n\n // invalidate cache when CP key changes\n ComputedPropertyPrototype.didChange = function (obj, keyName) {\n // _suspended is set via a CP.set to ensure we don't clear\n // the cached value set by the setter\n if (this._volatile || this._suspended === obj) {\n return;\n }\n\n // don't create objects just to invalidate\n var meta$$1 = exports.peekMeta(obj);\n if (meta$$1 === undefined || meta$$1.source !== obj) {\n return;\n }\n\n var cache = meta$$1.readableCache();\n if (cache !== undefined && cache[keyName] !== undefined) {\n cache[keyName] = undefined;\n removeDependentKeys(this, obj, keyName, meta$$1);\n }\n };\n\n ComputedPropertyPrototype.get = function (obj, keyName) {\n if (this._volatile) {\n return this._getter.call(obj, keyName);\n }\n\n var meta$$1 = meta(obj);\n var cache = meta$$1.writableCache();\n\n var result = cache[keyName];\n if (result === UNDEFINED) {\n return undefined;\n } else if (result !== undefined) {\n return result;\n }\n\n var ret = this._getter.call(obj, keyName);\n\n cache[keyName] = ret === undefined ? UNDEFINED : ret;\n\n var chainWatchers = meta$$1.readableChainWatchers();\n if (chainWatchers !== undefined) {\n chainWatchers.revalidate(keyName);\n }\n addDependentKeys(this, obj, keyName, meta$$1);\n\n return ret;\n };\n\n ComputedPropertyPrototype.set = function (obj, keyName, value) {\n if (this._readOnly) {\n this._throwReadOnlyError(obj, keyName);\n }\n\n if (!this._setter) {\n return this.clobberSet(obj, keyName, value);\n }\n\n if (this._volatile) {\n return this.volatileSet(obj, keyName, value);\n }\n\n return this.setWithSuspend(obj, keyName, value);\n };\n\n ComputedPropertyPrototype._throwReadOnlyError = function (obj, keyName) {\n throw new emberDebug.Error('Cannot set read-only property \"' + keyName + '\" on object: ' + emberUtils.inspect(obj));\n };\n\n ComputedPropertyPrototype.clobberSet = function (obj, keyName, value) {\n var cachedValue = cacheFor(obj, keyName);\n defineProperty(obj, keyName, null, cachedValue);\n set(obj, keyName, value);\n return value;\n };\n\n ComputedPropertyPrototype.volatileSet = function (obj, keyName, value) {\n return this._setter.call(obj, keyName, value);\n };\n\n ComputedPropertyPrototype.setWithSuspend = function (obj, keyName, value) {\n var oldSuspended = this._suspended;\n this._suspended = obj;\n try {\n return this._set(obj, keyName, value);\n } finally {\n this._suspended = oldSuspended;\n }\n };\n\n ComputedPropertyPrototype._set = function (obj, keyName, value) {\n var meta$$1 = meta(obj);\n var cache = meta$$1.writableCache();\n\n var val = cache[keyName];\n var hadCachedValue = val !== undefined;\n\n var cachedValue = void 0;\n if (hadCachedValue && val !== UNDEFINED) {\n cachedValue = val;\n }\n\n var ret = this._setter.call(obj, keyName, value, cachedValue);\n\n // allows setter to return the same value that is cached already\n if (hadCachedValue && cachedValue === ret) {\n return ret;\n }\n\n propertyWillChange(obj, keyName, meta$$1);\n\n if (!hadCachedValue) {\n addDependentKeys(this, obj, keyName, meta$$1);\n }\n\n cache[keyName] = ret === undefined ? UNDEFINED : ret;\n\n propertyDidChange(obj, keyName, meta$$1);\n\n return ret;\n };\n\n /* called before property is overridden */\n ComputedPropertyPrototype.teardown = function (obj, keyName, meta$$1) {\n if (this._volatile) {\n return;\n }\n var cache = meta$$1.readableCache();\n if (cache !== undefined && cache[keyName] !== undefined) {\n removeDependentKeys(this, obj, keyName, meta$$1);\n cache[keyName] = undefined;\n }\n };\n\n /**\n This helper returns a new property descriptor that wraps the passed\n computed property function. You can use this helper to define properties\n with mixins or via `defineProperty()`.\n \n If you pass a function as an argument, it will be used as a getter. A computed\n property defined in this way might look like this:\n \n ```js\n import EmberObject, { computed } from '@ember/object';\n \n let Person = EmberObject.extend({\n init() {\n this._super(...arguments);\n \n this.firstName = 'Betty';\n this.lastName = 'Jones';\n },\n \n fullName: computed('firstName', 'lastName', function() {\n return `${this.get('firstName')} ${this.get('lastName')}`;\n })\n });\n \n let client = Person.create();\n \n client.get('fullName'); // 'Betty Jones'\n \n client.set('lastName', 'Fuller');\n client.get('fullName'); // 'Betty Fuller'\n ```\n \n You can pass a hash with two functions, `get` and `set`, as an\n argument to provide both a getter and setter:\n \n ```js\n import EmberObject, { computed } from '@ember/object';\n \n let Person = EmberObject.extend({\n init() {\n this._super(...arguments);\n \n this.firstName = 'Betty';\n this.lastName = 'Jones';\n },\n \n fullName: computed('firstName', 'lastName', {\n get(key) {\n return `${this.get('firstName')} ${this.get('lastName')}`;\n },\n set(key, value) {\n let [firstName, lastName] = value.split(/\\s+/);\n this.setProperties({ firstName, lastName });\n return value;\n }\n })\n });\n \n let client = Person.create();\n client.get('firstName'); // 'Betty'\n \n client.set('fullName', 'Carroll Fuller');\n client.get('firstName'); // 'Carroll'\n ```\n \n The `set` function should accept two parameters, `key` and `value`. The value\n returned from `set` will be the new value of the property.\n \n _Note: This is the preferred way to define computed properties when writing third-party\n libraries that depend on or use Ember, since there is no guarantee that the user\n will have [prototype Extensions](https://emberjs.com/guides/configuring-ember/disabling-prototype-extensions/) enabled._\n \n The alternative syntax, with prototype extensions, might look like:\n \n ```js\n fullName: function() {\n return this.get('firstName') + ' ' + this.get('lastName');\n }.property('firstName', 'lastName')\n ```\n \n @method computed\n @for @ember/object\n @static\n @param {String} [dependentKeys*] Optional dependent keys that trigger this computed property.\n @param {Function} func The computed property function.\n @return {ComputedProperty} property descriptor instance\n @public\n */\n\n\n /**\n Returns the cached value for a property, if one exists.\n This can be useful for peeking at the value of a computed\n property that is generated lazily, without accidentally causing\n it to be created.\n \n @method cacheFor\n @static\n @for @ember/object/internals\n @param {Object} obj the object whose property you want to check\n @param {String} key the name of the property whose cached value you want\n to return\n @return {Object} the cached value\n @public\n */\n function cacheFor(obj, key) {\n var meta$$1 = exports.peekMeta(obj);\n var cache = meta$$1 !== undefined ? meta$$1.source === obj && meta$$1.readableCache() : undefined;\n var ret = cache !== undefined ? cache[key] : undefined;\n\n if (ret === UNDEFINED) {\n return undefined;\n }\n return ret;\n }\n\n cacheFor.set = function (cache, key, value) {\n if (value === undefined) {\n cache[key] = UNDEFINED;\n } else {\n cache[key] = value;\n }\n };\n\n cacheFor.get = function (cache, key) {\n var ret = cache[key];\n if (ret === UNDEFINED) {\n return undefined;\n }\n return ret;\n };\n\n cacheFor.remove = function (cache, key) {\n cache[key] = undefined;\n };\n\n var CONSUMED = {};\n\n var AliasedProperty = function (_Descriptor) {\n emberBabel.inherits(AliasedProperty, _Descriptor);\n\n function AliasedProperty(altKey) {\n\n var _this = emberBabel.possibleConstructorReturn(this, _Descriptor.call(this));\n\n _this.isDescriptor = true;\n _this.altKey = altKey;\n _this._dependentKeys = [altKey];\n return _this;\n }\n\n AliasedProperty.prototype.setup = function (obj, keyName) {\n true && !(this.altKey !== keyName) && emberDebug.assert('Setting alias \\'' + keyName + '\\' on self', this.altKey !== keyName);\n\n var meta$$1 = meta(obj);\n if (meta$$1.peekWatching(keyName)) {\n addDependentKeys(this, obj, keyName, meta$$1);\n }\n };\n\n AliasedProperty.prototype.teardown = function (obj, keyName, meta$$1) {\n if (meta$$1.peekWatching(keyName)) {\n removeDependentKeys(this, obj, keyName, meta$$1);\n }\n };\n\n AliasedProperty.prototype.willWatch = function (obj, keyName, meta$$1) {\n addDependentKeys(this, obj, keyName, meta$$1);\n };\n\n AliasedProperty.prototype.didUnwatch = function (obj, keyName, meta$$1) {\n removeDependentKeys(this, obj, keyName, meta$$1);\n };\n\n AliasedProperty.prototype.get = function (obj, keyName) {\n var ret = get(obj, this.altKey);\n var meta$$1 = meta(obj);\n var cache = meta$$1.writableCache();\n if (cache[keyName] !== CONSUMED) {\n cache[keyName] = CONSUMED;\n addDependentKeys(this, obj, keyName, meta$$1);\n }\n return ret;\n };\n\n AliasedProperty.prototype.set = function (obj, keyName, value) {\n return set(obj, this.altKey, value);\n };\n\n AliasedProperty.prototype.readOnly = function () {\n this.set = AliasedProperty_readOnlySet;\n return this;\n };\n\n AliasedProperty.prototype.oneWay = function () {\n this.set = AliasedProperty_oneWaySet;\n return this;\n };\n\n return AliasedProperty;\n }(Descriptor);\n\n function AliasedProperty_readOnlySet(obj, keyName) {\n throw new emberDebug.Error('Cannot set read-only property \\'' + keyName + '\\' on object: ' + emberUtils.inspect(obj));\n }\n\n function AliasedProperty_oneWaySet(obj, keyName, value) {\n defineProperty(obj, keyName, null);\n return set(obj, keyName, value);\n }\n\n // Backwards compatibility with Ember Data.\n AliasedProperty.prototype._meta = undefined;\n AliasedProperty.prototype.meta = ComputedProperty.prototype.meta;\n\n /**\n @module @ember/polyfills\n */\n /**\n Merge the contents of two objects together into the first object.\n \n ```javascript\n import { merge } from '@ember/polyfills';\n \n merge({ first: 'Tom' }, { last: 'Dale' }); // { first: 'Tom', last: 'Dale' }\n var a = { first: 'Yehuda' };\n var b = { last: 'Katz' };\n merge(a, b); // a == { first: 'Yehuda', last: 'Katz' }, b == { last: 'Katz' }\n ```\n \n @method merge\n @static\n @for @ember/polyfills\n @param {Object} original The object to merge into\n @param {Object} updates The object to copy properties from\n @return {Object}\n @public\n */\n\n\n /**\n @module ember\n */\n\n /**\n Used internally to allow changing properties in a backwards compatible way, and print a helpful\n deprecation warning.\n \n @method deprecateProperty\n @param {Object} object The object to add the deprecated property to.\n @param {String} deprecatedKey The property to add (and print deprecation warnings upon accessing).\n @param {String} newKey The property that will be aliased.\n @private\n @since 1.7.0\n */\n\n /* eslint no-console:off */\n /* global console */\n\n /**\n @module @ember/instrumentation\n @private\n */\n\n /**\n The purpose of the Ember Instrumentation module is\n to provide efficient, general-purpose instrumentation\n for Ember.\n \n Subscribe to a listener by using `subscribe`:\n \n ```javascript\n import { subscribe } from '@ember/instrumentation';\n \n subscribe(\"render\", {\n before(name, timestamp, payload) {\n \n },\n \n after(name, timestamp, payload) {\n \n }\n });\n ```\n \n If you return a value from the `before` callback, that same\n value will be passed as a fourth parameter to the `after`\n callback.\n \n Instrument a block of code by using `instrument`:\n \n ```javascript\n import { instrument } from '@ember/instrumentation';\n \n instrument(\"render.handlebars\", payload, function() {\n // rendering logic\n }, binding);\n ```\n \n Event names passed to `instrument` are namespaced\n by periods, from more general to more specific. Subscribers\n can listen for events by whatever level of granularity they\n are interested in.\n \n In the above example, the event is `render.handlebars`,\n and the subscriber listened for all events beginning with\n `render`. It would receive callbacks for events named\n `render`, `render.handlebars`, `render.container`, or\n even `render.handlebars.layout`.\n \n @class Instrumentation\n @static\n @private\n */\n var subscribers = [];\n var cache = {};\n\n function populateListeners(name) {\n var listeners = [],\n i;\n var subscriber = void 0;\n\n for (i = 0; i < subscribers.length; i++) {\n subscriber = subscribers[i];\n if (subscriber.regex.test(name)) {\n listeners.push(subscriber.object);\n }\n }\n\n cache[name] = listeners;\n return listeners;\n }\n\n var time = function () {\n var perf = 'undefined' !== typeof window ? window.performance || {} : {};\n var fn = perf.now || perf.mozNow || perf.webkitNow || perf.msNow || perf.oNow;\n // fn.bind will be available in all the browsers that support the advanced window.performance... ;-)\n return fn ? fn.bind(perf) : function () {\n return +new Date();\n };\n }();\n\n /**\n Notifies event's subscribers, calls `before` and `after` hooks.\n \n @method instrument\n @for @ember/instrumentation\n @static\n @param {String} [name] Namespaced event name.\n @param {Object} _payload\n @param {Function} callback Function that you're instrumenting.\n @param {Object} binding Context that instrument function is called with.\n @private\n */\n function instrument(name, _payload, callback, binding) {\n if (arguments.length <= 3 && typeof _payload === 'function') {\n binding = callback;\n callback = _payload;\n _payload = undefined;\n }\n if (subscribers.length === 0) {\n return callback.call(binding);\n }\n var payload = _payload || {};\n var finalizer = _instrumentStart(name, function () {\n return payload;\n });\n\n if (finalizer) {\n return withFinalizer(callback, finalizer, payload, binding);\n } else {\n return callback.call(binding);\n }\n }\n\n exports.flaggedInstrument = void 0;\n if (ember_features.EMBER_IMPROVED_INSTRUMENTATION) {\n exports.flaggedInstrument = instrument;\n } else {\n exports.flaggedInstrument = function (name, payload, callback) {\n return callback();\n };\n }\n function withFinalizer(callback, finalizer, payload, binding) {\n var result = void 0;\n try {\n result = callback.call(binding);\n } catch (e) {\n payload.exception = e;\n result = payload;\n } finally {\n finalizer();\n }\n return result;\n }\n\n function NOOP() {}\n\n // private for now\n function _instrumentStart(name, _payload, _payloadParam) {\n if (subscribers.length === 0) {\n return NOOP;\n }\n\n var listeners = cache[name];\n\n if (!listeners) {\n listeners = populateListeners(name);\n }\n\n if (listeners.length === 0) {\n return NOOP;\n }\n\n var payload = _payload(_payloadParam);\n\n var STRUCTURED_PROFILE = emberEnvironment.ENV.STRUCTURED_PROFILE;\n var timeName = void 0;\n if (STRUCTURED_PROFILE) {\n timeName = name + ': ' + payload.object;\n console.time(timeName);\n }\n\n var beforeValues = new Array(listeners.length);\n var i = void 0,\n listener = void 0;\n var timestamp = time();\n for (i = 0; i < listeners.length; i++) {\n listener = listeners[i];\n beforeValues[i] = listener.before(name, timestamp, payload);\n }\n\n return function () {\n var i = void 0,\n listener = void 0;\n var timestamp = time();\n for (i = 0; i < listeners.length; i++) {\n listener = listeners[i];\n if (typeof listener.after === 'function') {\n listener.after(name, timestamp, payload, beforeValues[i]);\n }\n }\n\n if (STRUCTURED_PROFILE) {\n console.timeEnd(timeName);\n }\n };\n }\n\n /**\n Subscribes to a particular event or instrumented block of code.\n \n @method subscribe\n @for @ember/instrumentation\n @static\n \n @param {String} [pattern] Namespaced event name.\n @param {Object} [object] Before and After hooks.\n \n @return {Subscriber}\n @private\n */\n\n\n /**\n Unsubscribes from a particular event or instrumented block of code.\n \n @method unsubscribe\n @for @ember/instrumentation\n @static\n \n @param {Object} [subscriber]\n @private\n */\n\n\n /**\n Resets `Instrumentation` by flushing list of subscribers.\n \n @method reset\n @for @ember/instrumentation\n @static\n @private\n */\n\n\n var onerror = void 0;\n var onErrorTarget = {\n get onerror() {\n return onerror;\n }\n };\n\n // Ember.onerror getter\n\n // Ember.onerror setter\n\n\n var dispatchOverride = void 0;\n\n // allows testing adapter to override dispatch\n\n\n /**\n @module @ember/utils\n */\n /**\n Returns true if the passed value is null or undefined. This avoids errors\n from JSLint complaining about use of ==, which can be technically\n confusing.\n \n ```javascript\n isNone(); // true\n isNone(null); // true\n isNone(undefined); // true\n isNone(''); // false\n isNone([]); // false\n isNone(function() {}); // false\n ```\n \n @method isNone\n @static\n @for @ember/utils\n @param {Object} obj Value to test\n @return {Boolean}\n @public\n */\n function isNone(obj) {\n return obj === null || obj === undefined;\n }\n\n /**\n @module @ember/utils\n */\n /**\n Verifies that a value is `null` or `undefined`, an empty string, or an empty\n array.\n \n Constrains the rules on `isNone` by returning true for empty strings and\n empty arrays.\n \n ```javascript\n isEmpty(); // true\n isEmpty(null); // true\n isEmpty(undefined); // true\n isEmpty(''); // true\n isEmpty([]); // true\n isEmpty({}); // false\n isEmpty('Adam Hawkins'); // false\n isEmpty([0,1,2]); // false\n isEmpty('\\n\\t'); // false\n isEmpty(' '); // false\n ```\n \n @method isEmpty\n @static\n @for @ember/utils\n @param {Object} obj Value to test\n @return {Boolean}\n @public\n */\n function isEmpty(obj) {\n var none = isNone(obj),\n size,\n length;\n if (none) {\n return none;\n }\n\n if (typeof obj.size === 'number') {\n return !obj.size;\n }\n\n var objectType = typeof obj;\n\n if (objectType === 'object') {\n size = get(obj, 'size');\n\n if (typeof size === 'number') {\n return !size;\n }\n }\n\n if (typeof obj.length === 'number' && objectType !== 'function') {\n return !obj.length;\n }\n\n if (objectType === 'object') {\n length = get(obj, 'length');\n\n if (typeof length === 'number') {\n return !length;\n }\n }\n\n return false;\n }\n\n /**\n @module @ember/utils\n */\n /**\n A value is blank if it is empty or a whitespace string.\n \n ```javascript\n import { isBlank } from '@ember/utils';\n \n isBlank(); // true\n isBlank(null); // true\n isBlank(undefined); // true\n isBlank(''); // true\n isBlank([]); // true\n isBlank('\\n\\t'); // true\n isBlank(' '); // true\n isBlank({}); // false\n isBlank('\\n\\t Hello'); // false\n isBlank('Hello world'); // false\n isBlank([1,2,3]); // false\n ```\n \n @method isBlank\n @static\n @for @ember/utils\n @param {Object} obj Value to test\n @return {Boolean}\n @since 1.5.0\n @public\n */\n function isBlank(obj) {\n return isEmpty(obj) || typeof obj === 'string' && /\\S/.test(obj) === false;\n }\n\n /**\n @module @ember/utils\n */\n /**\n A value is present if it not `isBlank`.\n \n ```javascript\n isPresent(); // false\n isPresent(null); // false\n isPresent(undefined); // false\n isPresent(''); // false\n isPresent(' '); // false\n isPresent('\\n\\t'); // false\n isPresent([]); // false\n isPresent({ length: 0 }) // false\n isPresent(false); // true\n isPresent(true); // true\n isPresent('string'); // true\n isPresent(0); // true\n isPresent(function() {}) // true\n isPresent({}); // true\n isPresent(false); // true\n isPresent('\\n\\t Hello'); // true\n isPresent([1,2,3]); // true\n ```\n \n @method isPresent\n @static\n @for @ember/utils\n @param {Object} obj Value to test\n @return {Boolean}\n @since 1.8.0\n @public\n */\n\n\n var backburner$1 = new Backburner(['sync', 'actions', 'destroy'], {\n GUID_KEY: emberUtils.GUID_KEY,\n sync: {\n before: beginPropertyChanges,\n after: endPropertyChanges\n },\n defaultQueue: 'actions',\n onBegin: function (current) {\n run.currentRunLoop = current;\n },\n onEnd: function (current, next) {\n run.currentRunLoop = next;\n },\n onErrorTarget: onErrorTarget,\n onErrorMethod: 'onerror'\n });\n\n /**\n @module @ember/runloop\n */\n // ..........................................................\n // run - this is ideally the only public API the dev sees\n //\n\n /**\n Runs the passed target and method inside of a RunLoop, ensuring any\n deferred actions including bindings and views updates are flushed at the\n end.\n \n Normally you should not need to invoke this method yourself. However if\n you are implementing raw event handlers when interfacing with other\n libraries or plugins, you should probably wrap all of your code inside this\n call.\n \n ```javascript\n import { run } from '@ember/runloop';\n \n run(function() {\n // code to be executed within a RunLoop\n });\n ```\n @method run\n @for @ember/runloop\n @static\n @param {Object} [target] target of method to call\n @param {Function|String} method Method to invoke.\n May be a function or a string. If you pass a string\n then it will be looked up on the passed target.\n @param {Object} [args*] Any additional arguments you wish to pass to the method.\n @return {Object} return value from invoking the passed function.\n @public\n */\n function run() {\n return backburner$1.run.apply(backburner$1, arguments);\n }\n\n /**\n If no run-loop is present, it creates a new one. If a run loop is\n present it will queue itself to run on the existing run-loops action\n queue.\n \n Please note: This is not for normal usage, and should be used sparingly.\n \n If invoked when not within a run loop:\n \n ```javascript\n import { join } from '@ember/runloop';\n \n join(function() {\n // creates a new run-loop\n });\n ```\n \n Alternatively, if called within an existing run loop:\n \n ```javascript\n import { run, join } from '@ember/runloop';\n \n run(function() {\n // creates a new run-loop\n \n join(function() {\n // joins with the existing run-loop, and queues for invocation on\n // the existing run-loops action queue.\n });\n });\n ```\n \n @method join\n @static\n @for @ember/runloop\n @param {Object} [target] target of method to call\n @param {Function|String} method Method to invoke.\n May be a function or a string. If you pass a string\n then it will be looked up on the passed target.\n @param {Object} [args*] Any additional arguments you wish to pass to the method.\n @return {Object} Return value from invoking the passed function. Please note,\n when called within an existing loop, no return value is possible.\n @public\n */\n run.join = function () {\n return backburner$1.join.apply(backburner$1, arguments);\n };\n\n /**\n Allows you to specify which context to call the specified function in while\n adding the execution of that function to the Ember run loop. This ability\n makes this method a great way to asynchronously integrate third-party libraries\n into your Ember application.\n \n `bind` takes two main arguments, the desired context and the function to\n invoke in that context. Any additional arguments will be supplied as arguments\n to the function that is passed in.\n \n Let's use the creation of a TinyMCE component as an example. Currently,\n TinyMCE provides a setup configuration option we can use to do some processing\n after the TinyMCE instance is initialized but before it is actually rendered.\n We can use that setup option to do some additional setup for our component.\n The component itself could look something like the following:\n \n ```app/components/rich-text-editor.js\n import Component from '@ember/component';\n import { on } from '@ember/object/evented';\n import { bind } from '@ember/runloop';\n \n export default Component.extend({\n initializeTinyMCE: on('didInsertElement', function() {\n tinymce.init({\n selector: '#' + this.$().prop('id'),\n setup: Ember.run.bind(this, this.setupEditor)\n });\n }),\n \n didInsertElement() {\n tinymce.init({\n selector: '#' + this.$().prop('id'),\n setup: Ember.run.bind(this, this.setupEditor)\n });\n }\n \n setupEditor(editor) {\n this.set('editor', editor);\n \n editor.on('change', function() {\n console.log('content changed!');\n });\n }\n });\n ```\n \n In this example, we use Ember.run.bind to bind the setupEditor method to the\n context of the RichTextEditor component and to have the invocation of that\n method be safely handled and executed by the Ember run loop.\n \n @method bind\n @static\n @for @ember/runloop\n @param {Object} [target] target of method to call\n @param {Function|String} method Method to invoke.\n May be a function or a string. If you pass a string\n then it will be looked up on the passed target.\n @param {Object} [args*] Any additional arguments you wish to pass to the method.\n @return {Function} returns a new function that will always have a particular context\n @since 1.4.0\n @public\n */\n run.bind = function () {\n var _len, curried, _key;\n\n for (_len = arguments.length, curried = Array(_len), _key = 0; _key < _len; _key++) {\n curried[_key] = arguments[_key];\n }\n\n return function () {\n var _len2, args, _key2;\n\n for (_len2 = arguments.length, args = Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n args[_key2] = arguments[_key2];\n }\n\n return run.join.apply(run, curried.concat(args));\n };\n };\n\n run.backburner = backburner$1;\n run.currentRunLoop = null;\n run.queues = backburner$1.queueNames;\n\n /**\n Begins a new RunLoop. Any deferred actions invoked after the begin will\n be buffered until you invoke a matching call to `run.end()`. This is\n a lower-level way to use a RunLoop instead of using `run()`.\n \n ```javascript\n import { begin, end } from '@ember/runloop';\n \n begin();\n // code to be executed within a RunLoop\n end();\n ```\n \n @method begin\n @static\n @for @ember/runloop\n @return {void}\n @public\n */\n run.begin = function () {\n backburner$1.begin();\n };\n\n /**\n Ends a RunLoop. This must be called sometime after you call\n `run.begin()` to flush any deferred actions. This is a lower-level way\n to use a RunLoop instead of using `run()`.\n \n ```javascript\n import { begin, end } from '@ember/runloop';\n \n begin();\n // code to be executed within a RunLoop\n end();\n ```\n \n @method end\n @static\n @for @ember/runloop\n @return {void}\n @public\n */\n run.end = function () {\n backburner$1.end();\n };\n\n /**\n Array of named queues. This array determines the order in which queues\n are flushed at the end of the RunLoop. You can define your own queues by\n simply adding the queue name to this array. Normally you should not need\n to inspect or modify this property.\n \n @property queues\n @type Array\n @default ['sync', 'actions', 'destroy']\n @private\n */\n\n /**\n Adds the passed target/method and any optional arguments to the named\n queue to be executed at the end of the RunLoop. If you have not already\n started a RunLoop when calling this method one will be started for you\n automatically.\n \n At the end of a RunLoop, any methods scheduled in this way will be invoked.\n Methods will be invoked in an order matching the named queues defined in\n the `run.queues` property.\n \n ```javascript\n import { schedule } from '@ember/runloop';\n \n schedule('sync', this, function() {\n // this will be executed in the first RunLoop queue, when bindings are synced\n console.log('scheduled on sync queue');\n });\n \n schedule('actions', this, function() {\n // this will be executed in the 'actions' queue, after bindings have synced.\n console.log('scheduled on actions queue');\n });\n \n // Note the functions will be run in order based on the run queues order.\n // Output would be:\n // scheduled on sync queue\n // scheduled on actions queue\n ```\n \n @method schedule\n @static\n @for @ember/runloop\n @param {String} queue The name of the queue to schedule against.\n Default queues are 'sync' and 'actions'\n @param {Object} [target] target object to use as the context when invoking a method.\n @param {String|Function} method The method to invoke. If you pass a string it\n will be resolved on the target object at the time the scheduled item is\n invoked allowing you to change the target function.\n @param {Object} [arguments*] Optional arguments to be passed to the queued method.\n @return {*} Timer information for use in canceling, see `run.cancel`.\n @public\n */\n run.schedule = function () /* queue, target, method */{\n true && !(run.currentRunLoop || !emberDebug.isTesting()) && emberDebug.assert('You have turned on testing mode, which disabled the run-loop\\'s autorun. ' + 'You will need to wrap any code with asynchronous side-effects in a run', run.currentRunLoop || !emberDebug.isTesting());\n\n return backburner$1.schedule.apply(backburner$1, arguments);\n };\n\n // Used by global test teardown\n run.hasScheduledTimers = function () {\n return backburner$1.hasTimers();\n };\n\n // Used by global test teardown\n run.cancelTimers = function () {\n backburner$1.cancelTimers();\n };\n\n /**\n Immediately flushes any events scheduled in the 'sync' queue. Bindings\n use this queue so this method is a useful way to immediately force all\n bindings in the application to sync.\n \n You should call this method anytime you need any changed state to propagate\n throughout the app immediately without repainting the UI (which happens\n in the later 'render' queue added by the `ember-views` package).\n \n ```javascript\n run.sync();\n ```\n \n @method sync\n @static\n @for @ember/runloop\n @return {void}\n @private\n */\n run.sync = function () {\n if (backburner$1.currentInstance) {\n backburner$1.currentInstance.queues.sync.flush();\n }\n };\n\n /**\n Invokes the passed target/method and optional arguments after a specified\n period of time. The last parameter of this method must always be a number\n of milliseconds.\n \n You should use this method whenever you need to run some action after a\n period of time instead of using `setTimeout()`. This method will ensure that\n items that expire during the same script execution cycle all execute\n together, which is often more efficient than using a real setTimeout.\n \n ```javascript\n import { later } from '@ember/runloop';\n \n later(myContext, function() {\n // code here will execute within a RunLoop in about 500ms with this == myContext\n }, 500);\n ```\n \n @method later\n @static\n @for @ember/runloop\n @param {Object} [target] target of method to invoke\n @param {Function|String} method The method to invoke.\n If you pass a string it will be resolved on the\n target at the time the method is invoked.\n @param {Object} [args*] Optional arguments to pass to the timeout.\n @param {Number} wait Number of milliseconds to wait.\n @return {*} Timer information for use in canceling, see `run.cancel`.\n @public\n */\n run.later = function () /*target, method*/{\n return backburner$1.later.apply(backburner$1, arguments);\n };\n\n /**\n Schedule a function to run one time during the current RunLoop. This is equivalent\n to calling `scheduleOnce` with the \"actions\" queue.\n \n @method once\n @static\n @for @ember/runloop\n @param {Object} [target] The target of the method to invoke.\n @param {Function|String} method The method to invoke.\n If you pass a string it will be resolved on the\n target at the time the method is invoked.\n @param {Object} [args*] Optional arguments to pass to the timeout.\n @return {Object} Timer information for use in canceling, see `run.cancel`.\n @public\n */\n run.once = function () {\n var _len3, args, _key3;\n\n true && !(run.currentRunLoop || !emberDebug.isTesting()) && emberDebug.assert('You have turned on testing mode, which disabled the run-loop\\'s autorun. ' + 'You will need to wrap any code with asynchronous side-effects in a run', run.currentRunLoop || !emberDebug.isTesting());\n\n for (_len3 = arguments.length, args = Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {\n args[_key3] = arguments[_key3];\n }\n\n args.unshift('actions');\n return backburner$1.scheduleOnce.apply(backburner$1, args);\n };\n\n /**\n Schedules a function to run one time in a given queue of the current RunLoop.\n Calling this method with the same queue/target/method combination will have\n no effect (past the initial call).\n \n Note that although you can pass optional arguments these will not be\n considered when looking for duplicates. New arguments will replace previous\n calls.\n \n ```javascript\n import { run, scheduleOnce } from '@ember/runloop';\n \n function sayHi() {\n console.log('hi');\n }\n \n run(function() {\n scheduleOnce('afterRender', myContext, sayHi);\n scheduleOnce('afterRender', myContext, sayHi);\n // sayHi will only be executed once, in the afterRender queue of the RunLoop\n });\n ```\n \n Also note that for `run.scheduleOnce` to prevent additional calls, you need to\n pass the same function instance. The following case works as expected:\n \n ```javascript\n function log() {\n console.log('Logging only once');\n }\n \n function scheduleIt() {\n scheduleOnce('actions', myContext, log);\n }\n \n scheduleIt();\n scheduleIt();\n ```\n \n But this other case will schedule the function multiple times:\n \n ```javascript\n import { scheduleOnce } from '@ember/runloop';\n \n function scheduleIt() {\n scheduleOnce('actions', myContext, function() {\n console.log('Closure');\n });\n }\n \n scheduleIt();\n scheduleIt();\n \n // \"Closure\" will print twice, even though we're using `run.scheduleOnce`,\n // because the function we pass to it won't match the\n // previously scheduled operation.\n ```\n \n Available queues, and their order, can be found at `run.queues`\n \n @method scheduleOnce\n @static\n @for @ember/runloop\n @param {String} [queue] The name of the queue to schedule against. Default queues are 'sync' and 'actions'.\n @param {Object} [target] The target of the method to invoke.\n @param {Function|String} method The method to invoke.\n If you pass a string it will be resolved on the\n target at the time the method is invoked.\n @param {Object} [args*] Optional arguments to pass to the timeout.\n @return {Object} Timer information for use in canceling, see `run.cancel`.\n @public\n */\n run.scheduleOnce = function () /*queue, target, method*/{\n true && !(run.currentRunLoop || !emberDebug.isTesting()) && emberDebug.assert('You have turned on testing mode, which disabled the run-loop\\'s autorun. ' + 'You will need to wrap any code with asynchronous side-effects in a run', run.currentRunLoop || !emberDebug.isTesting());\n\n return backburner$1.scheduleOnce.apply(backburner$1, arguments);\n };\n\n /**\n Schedules an item to run from within a separate run loop, after\n control has been returned to the system. This is equivalent to calling\n `run.later` with a wait time of 1ms.\n \n ```javascript\n import { next } from '@ember/runloop';\n \n next(myContext, function() {\n // code to be executed in the next run loop,\n // which will be scheduled after the current one\n });\n ```\n \n Multiple operations scheduled with `run.next` will coalesce\n into the same later run loop, along with any other operations\n scheduled by `run.later` that expire right around the same\n time that `run.next` operations will fire.\n \n Note that there are often alternatives to using `run.next`.\n For instance, if you'd like to schedule an operation to happen\n after all DOM element operations have completed within the current\n run loop, you can make use of the `afterRender` run loop queue (added\n by the `ember-views` package, along with the preceding `render` queue\n where all the DOM element operations happen).\n \n Example:\n \n ```app/components/my-component.js\n import Component from '@ember/component';\n import { scheduleOnce } from '@ember/runloop';\n \n export Component.extend({\n didInsertElement() {\n this._super(...arguments);\n scheduleOnce('afterRender', this, 'processChildElements');\n },\n \n processChildElements() {\n // ... do something with component's child component\n // elements after they've finished rendering, which\n // can't be done within this component's\n // `didInsertElement` hook because that gets run\n // before the child elements have been added to the DOM.\n }\n });\n ```\n \n One benefit of the above approach compared to using `run.next` is\n that you will be able to perform DOM/CSS operations before unprocessed\n elements are rendered to the screen, which may prevent flickering or\n other artifacts caused by delaying processing until after rendering.\n \n The other major benefit to the above approach is that `run.next`\n introduces an element of non-determinism, which can make things much\n harder to test, due to its reliance on `setTimeout`; it's much harder\n to guarantee the order of scheduled operations when they are scheduled\n outside of the current run loop, i.e. with `run.next`.\n \n @method next\n @static\n @for @ember/runloop\n @param {Object} [target] target of method to invoke\n @param {Function|String} method The method to invoke.\n If you pass a string it will be resolved on the\n target at the time the method is invoked.\n @param {Object} [args*] Optional arguments to pass to the timeout.\n @return {Object} Timer information for use in canceling, see `run.cancel`.\n @public\n */\n run.next = function () {\n var _len4, args, _key4;\n\n for (_len4 = arguments.length, args = Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {\n args[_key4] = arguments[_key4];\n }\n\n args.push(1);\n return backburner$1.later.apply(backburner$1, args);\n };\n\n /**\n Cancels a scheduled item. Must be a value returned by `later()`,\n `once()`, `scheduleOnce()`, `next()`, `debounce()`, or\n `throttle()`.\n \n ```javascript\n import {\n next,\n cancel,\n later,\n scheduleOnce,\n once,\n throttle,\n debounce\n } from '@ember/runloop';\n \n let runNext = next(myContext, function() {\n // will not be executed\n });\n \n cancel(runNext);\n \n let runLater = later(myContext, function() {\n // will not be executed\n }, 500);\n \n cancel(runLater);\n \n let runScheduleOnce = scheduleOnce('afterRender', myContext, function() {\n // will not be executed\n });\n \n cancel(runScheduleOnce);\n \n let runOnce = once(myContext, function() {\n // will not be executed\n });\n \n cancel(runOnce);\n \n let throttle = throttle(myContext, function() {\n // will not be executed\n }, 1, false);\n \n cancel(throttle);\n \n let debounce = debounce(myContext, function() {\n // will not be executed\n }, 1);\n \n cancel(debounce);\n \n let debounceImmediate = debounce(myContext, function() {\n // will be executed since we passed in true (immediate)\n }, 100, true);\n \n // the 100ms delay until this method can be called again will be canceled\n cancel(debounceImmediate);\n ```\n \n @method cancel\n @static\n @for @ember/runloop\n @param {Object} timer Timer object to cancel\n @return {Boolean} true if canceled or false/undefined if it wasn't found\n @public\n */\n run.cancel = function (timer) {\n return backburner$1.cancel(timer);\n };\n\n /**\n Delay calling the target method until the debounce period has elapsed\n with no additional debounce calls. If `debounce` is called again before\n the specified time has elapsed, the timer is reset and the entire period\n must pass again before the target method is called.\n \n This method should be used when an event may be called multiple times\n but the action should only be called once when the event is done firing.\n A common example is for scroll events where you only want updates to\n happen once scrolling has ceased.\n \n ```javascript\n import { debounce } from '@ember/runloop';\n \n function whoRan() {\n console.log(this.name + ' ran.');\n }\n \n let myContext = { name: 'debounce' };\n \n debounce(myContext, whoRan, 150);\n \n // less than 150ms passes\n debounce(myContext, whoRan, 150);\n \n // 150ms passes\n // whoRan is invoked with context myContext\n // console logs 'debounce ran.' one time.\n ```\n \n Immediate allows you to run the function immediately, but debounce\n other calls for this function until the wait time has elapsed. If\n `debounce` is called again before the specified time has elapsed,\n the timer is reset and the entire period must pass again before\n the method can be called again.\n \n ```javascript\n import { debounce } from '@ember/runloop';\n \n function whoRan() {\n console.log(this.name + ' ran.');\n }\n \n let myContext = { name: 'debounce' };\n \n debounce(myContext, whoRan, 150, true);\n \n // console logs 'debounce ran.' one time immediately.\n // 100ms passes\n debounce(myContext, whoRan, 150, true);\n \n // 150ms passes and nothing else is logged to the console and\n // the debouncee is no longer being watched\n debounce(myContext, whoRan, 150, true);\n \n // console logs 'debounce ran.' one time immediately.\n // 150ms passes and nothing else is logged to the console and\n // the debouncee is no longer being watched\n ```\n \n @method debounce\n @static\n @for @ember/runloop\n @param {Object} [target] target of method to invoke\n @param {Function|String} method The method to invoke.\n May be a function or a string. If you pass a string\n then it will be looked up on the passed target.\n @param {Object} [args*] Optional arguments to pass to the timeout.\n @param {Number} wait Number of milliseconds to wait.\n @param {Boolean} immediate Trigger the function on the leading instead\n of the trailing edge of the wait interval. Defaults to false.\n @return {Array} Timer information for use in canceling, see `run.cancel`.\n @public\n */\n run.debounce = function () {\n return backburner$1.debounce.apply(backburner$1, arguments);\n };\n\n /**\n Ensure that the target method is never called more frequently than\n the specified spacing period. The target method is called immediately.\n \n ```javascript\n import { throttle } from '@ember/runloop';\n \n function whoRan() {\n console.log(this.name + ' ran.');\n }\n \n let myContext = { name: 'throttle' };\n \n throttle(myContext, whoRan, 150);\n // whoRan is invoked with context myContext\n // console logs 'throttle ran.'\n \n // 50ms passes\n throttle(myContext, whoRan, 150);\n \n // 50ms passes\n throttle(myContext, whoRan, 150);\n \n // 150ms passes\n throttle(myContext, whoRan, 150);\n // whoRan is invoked with context myContext\n // console logs 'throttle ran.'\n ```\n \n @method throttle\n @static\n @for @ember/runloop\n @param {Object} [target] target of method to invoke\n @param {Function|String} method The method to invoke.\n May be a function or a string. If you pass a string\n then it will be looked up on the passed target.\n @param {Object} [args*] Optional arguments to pass to the timeout.\n @param {Number} spacing Number of milliseconds to space out requests.\n @param {Boolean} immediate Trigger the function on the leading instead\n of the trailing edge of the wait interval. Defaults to true.\n @return {Array} Timer information for use in canceling, see `run.cancel`.\n @public\n */\n run.throttle = function () {\n return backburner$1.throttle.apply(backburner$1, arguments);\n };\n\n /**\n Add a new named queue after the specified queue.\n \n The queue to add will only be added once.\n \n @method _addQueue\n @param {String} name the name of the queue to add.\n @param {String} after the name of the queue to add after.\n @private\n */\n run._addQueue = function (name, after) {\n if (run.queues.indexOf(name) === -1) {\n run.queues.splice(run.queues.indexOf(after) + 1, 0, name);\n }\n };\n\n /**\n @module ember\n */\n /**\n Helper class that allows you to register your library with Ember.\n \n Singleton created at `Ember.libraries`.\n \n @class Libraries\n @constructor\n @private\n */\n var Libraries = function () {\n function Libraries() {\n\n this._registry = [];\n this._coreLibIndex = 0;\n }\n\n Libraries.prototype._getLibraryByName = function (name) {\n var libs = this._registry,\n i;\n var count = libs.length;\n\n for (i = 0; i < count; i++) {\n if (libs[i].name === name) {\n return libs[i];\n }\n }\n };\n\n Libraries.prototype.register = function (name, version, isCoreLibrary) {\n var index = this._registry.length;\n\n if (!this._getLibraryByName(name)) {\n if (isCoreLibrary) {\n index = this._coreLibIndex++;\n }\n this._registry.splice(index, 0, { name: name, version: version });\n } else {\n true && emberDebug.warn('Library \"' + name + '\" is already registered with Ember.', false, { id: 'ember-metal.libraries-register' });\n }\n };\n\n Libraries.prototype.registerCoreLibrary = function (name, version) {\n this.register(name, version, true);\n };\n\n Libraries.prototype.deRegister = function (name) {\n var lib = this._getLibraryByName(name);\n var index = void 0;\n\n if (lib) {\n index = this._registry.indexOf(lib);\n this._registry.splice(index, 1);\n }\n };\n\n return Libraries;\n }();\n\n if (ember_features.EMBER_LIBRARIES_ISREGISTERED) {\n Libraries.prototype.isRegistered = function (name) {\n return !!this._getLibraryByName(name);\n };\n }\n\n var libraries = new Libraries();\n\n /**\n @module ember\n */\n\n /*\n JavaScript (before ES6) does not have a Map implementation. Objects,\n which are often used as dictionaries, may only have Strings as keys.\n \n Because Ember has a way to get a unique identifier for every object\n via `guidFor`, we can implement a performant Map with arbitrary\n keys. Because it is commonly used in low-level bookkeeping, Map is\n implemented as a pure JavaScript object for performance.\n \n This implementation follows the current iteration of the ES6 proposal for\n maps (http://wiki.ecmascript.org/doku.php?id=harmony:simple_maps_and_sets),\n with one exception: as we do not have the luxury of in-VM iteration, we implement a\n forEach method for iteration.\n \n Map is mocked out to look like an Ember object, so you can do\n `EmberMap.create()` for symmetry with other Ember classes.\n */\n\n function copyNull(obj) {\n var output = Object.create(null);\n\n for (var prop in obj) {\n // hasOwnPropery is not needed because obj is Object.create(null);\n output[prop] = obj[prop];\n }\n\n return output;\n }\n\n function copyMap(original, newObject) {\n var keys = original._keys.copy();\n var values = copyNull(original._values);\n\n newObject._keys = keys;\n newObject._values = values;\n newObject.size = original.size;\n\n return newObject;\n }\n\n /**\n This class is used internally by Ember and Ember Data.\n Please do not use it at this time. We plan to clean it up\n and add many tests soon.\n \n @class OrderedSet\n @namespace Ember\n @constructor\n @private\n */\n\n var OrderedSet = function () {\n function OrderedSet() {\n\n this.clear();\n }\n\n /**\n @method create\n @static\n @return {Ember.OrderedSet}\n @private\n */\n\n OrderedSet.create = function () {\n var Constructor = this;\n return new Constructor();\n };\n\n /**\n @method clear\n @private\n */\n\n OrderedSet.prototype.clear = function () {\n this.presenceSet = Object.create(null);\n this.list = [];\n this.size = 0;\n };\n\n /**\n @method add\n @param obj\n @param guid (optional, and for internal use)\n @return {Ember.OrderedSet}\n @private\n */\n\n OrderedSet.prototype.add = function (obj, _guid) {\n var guid = _guid || emberUtils.guidFor(obj);\n var presenceSet = this.presenceSet;\n var list = this.list;\n\n if (presenceSet[guid] !== true) {\n presenceSet[guid] = true;\n this.size = list.push(obj);\n }\n\n return this;\n };\n\n /**\n @since 1.8.0\n @method delete\n @param obj\n @param _guid (optional and for internal use only)\n @return {Boolean}\n @private\n */\n\n OrderedSet.prototype.delete = function (obj, _guid) {\n var guid = _guid || emberUtils.guidFor(obj),\n index;\n var presenceSet = this.presenceSet;\n var list = this.list;\n\n if (presenceSet[guid] === true) {\n delete presenceSet[guid];\n index = list.indexOf(obj);\n\n if (index > -1) {\n list.splice(index, 1);\n }\n this.size = list.length;\n return true;\n } else {\n return false;\n }\n };\n\n /**\n @method isEmpty\n @return {Boolean}\n @private\n */\n\n OrderedSet.prototype.isEmpty = function () {\n return this.size === 0;\n };\n\n /**\n @method has\n @param obj\n @return {Boolean}\n @private\n */\n\n OrderedSet.prototype.has = function (obj) {\n if (this.size === 0) {\n return false;\n }\n\n var guid = emberUtils.guidFor(obj);\n var presenceSet = this.presenceSet;\n\n return presenceSet[guid] === true;\n };\n\n /**\n @method forEach\n @param {Function} fn\n @param self\n @private\n */\n\n OrderedSet.prototype.forEach = function (fn /*, ...thisArg*/) {\n true && !(typeof fn === 'function') && emberDebug.assert(Object.prototype.toString.call(fn) + ' is not a function', typeof fn === 'function');\n\n if (this.size === 0) {\n return;\n }\n\n var list = this.list,\n i,\n _i;\n\n if (arguments.length === 2) {\n for (i = 0; i < list.length; i++) {\n fn.call(arguments[1], list[i]);\n }\n } else {\n for (_i = 0; _i < list.length; _i++) {\n fn(list[_i]);\n }\n }\n };\n\n /**\n @method toArray\n @return {Array}\n @private\n */\n\n OrderedSet.prototype.toArray = function () {\n return this.list.slice();\n };\n\n /**\n @method copy\n @return {Ember.OrderedSet}\n @private\n */\n\n OrderedSet.prototype.copy = function () {\n var Constructor = this.constructor;\n var set = new Constructor();\n\n set.presenceSet = copyNull(this.presenceSet);\n set.list = this.toArray();\n set.size = this.size;\n\n return set;\n };\n\n return OrderedSet;\n }();\n\n /**\n A Map stores values indexed by keys. Unlike JavaScript's\n default Objects, the keys of a Map can be any JavaScript\n object.\n \n Internally, a Map has two data structures:\n \n 1. `keys`: an OrderedSet of all of the existing keys\n 2. `values`: a JavaScript Object indexed by the `guidFor(key)`\n \n When a key/value pair is added for the first time, we\n add the key to the `keys` OrderedSet, and create or\n replace an entry in `values`. When an entry is deleted,\n we delete its entry in `keys` and `values`.\n \n @class Map\n @namespace Ember\n @private\n @constructor\n */\n\n var Map = function () {\n function Map() {\n\n this._keys = new OrderedSet();\n this._values = Object.create(null);\n this.size = 0;\n }\n\n /**\n @method create\n @static\n @private\n */\n\n Map.create = function () {\n var Constructor = this;\n return new Constructor();\n };\n\n /**\n Retrieve the value associated with a given key.\n @method get\n @param {*} key\n @return {*} the value associated with the key, or `undefined`\n @private\n */\n\n Map.prototype.get = function (key) {\n if (this.size === 0) {\n return;\n }\n\n var values = this._values;\n var guid = emberUtils.guidFor(key);\n\n return values[guid];\n };\n\n /**\n Adds a value to the map. If a value for the given key has already been\n provided, the new value will replace the old value.\n @method set\n @param {*} key\n @param {*} value\n @return {Ember.Map}\n @private\n */\n\n Map.prototype.set = function (key, value) {\n var keys = this._keys;\n var values = this._values;\n var guid = emberUtils.guidFor(key);\n\n // ensure we don't store -0\n var k = key === -0 ? 0 : key;\n\n keys.add(k, guid);\n\n values[guid] = value;\n\n this.size = keys.size;\n\n return this;\n };\n\n /**\n Removes a value from the map for an associated key.\n @since 1.8.0\n @method delete\n @param {*} key\n @return {Boolean} true if an item was removed, false otherwise\n @private\n */\n\n Map.prototype.delete = function (key) {\n if (this.size === 0) {\n return false;\n }\n // don't use ES6 \"delete\" because it will be annoying\n // to use in browsers that are not ES6 friendly;\n var keys = this._keys;\n var values = this._values;\n var guid = emberUtils.guidFor(key);\n\n if (keys.delete(key, guid)) {\n delete values[guid];\n this.size = keys.size;\n return true;\n } else {\n return false;\n }\n };\n\n /**\n Check whether a key is present.\n @method has\n @param {*} key\n @return {Boolean} true if the item was present, false otherwise\n @private\n */\n\n Map.prototype.has = function (key) {\n return this._keys.has(key);\n };\n\n /**\n Iterate over all the keys and values. Calls the function once\n for each key, passing in value, key, and the map being iterated over,\n in that order.\n The keys are guaranteed to be iterated over in insertion order.\n @method forEach\n @param {Function} callback\n @param {*} self if passed, the `this` value inside the\n callback. By default, `this` is the map.\n @private\n */\n\n Map.prototype.forEach = function (callback /*, ...thisArg*/) {\n true && !(typeof callback === 'function') && emberDebug.assert(Object.prototype.toString.call(callback) + ' is not a function', typeof callback === 'function');\n\n if (this.size === 0) {\n return;\n }\n\n var map = this;\n var cb = void 0,\n thisArg = void 0;\n\n if (arguments.length === 2) {\n thisArg = arguments[1];\n cb = function (key) {\n return callback.call(thisArg, map.get(key), key, map);\n };\n } else {\n cb = function (key) {\n return callback(map.get(key), key, map);\n };\n }\n\n this._keys.forEach(cb);\n };\n\n /**\n @method clear\n @private\n */\n\n Map.prototype.clear = function () {\n this._keys.clear();\n this._values = Object.create(null);\n this.size = 0;\n };\n\n /**\n @method copy\n @return {Ember.Map}\n @private\n */\n\n Map.prototype.copy = function () {\n return copyMap(this, new Map());\n };\n\n return Map;\n }();\n\n /**\n @class MapWithDefault\n @namespace Ember\n @extends Ember.Map\n @private\n @constructor\n @param [options]\n @param {*} [options.defaultValue]\n */\n\n var MapWithDefault = function (_Map) {\n emberBabel.inherits(MapWithDefault, _Map);\n\n function MapWithDefault(options) {\n\n var _this = emberBabel.possibleConstructorReturn(this, _Map.call(this));\n\n _this.defaultValue = options.defaultValue;\n return _this;\n }\n\n /**\n @method create\n @static\n @param [options]\n @param {*} [options.defaultValue]\n @return {Ember.MapWithDefault|Ember.Map} If options are passed, returns\n `MapWithDefault` otherwise returns `EmberMap`\n @private\n */\n\n MapWithDefault.create = function (options) {\n if (options) {\n return new MapWithDefault(options);\n } else {\n return new Map();\n }\n };\n\n /**\n Retrieve the value associated with a given key.\n @method get\n @param {*} key\n @return {*} the value associated with the key, or the default value\n @private\n */\n\n MapWithDefault.prototype.get = function (key) {\n var hasValue = this.has(key),\n defaultValue;\n\n if (hasValue) {\n return _Map.prototype.get.call(this, key);\n } else {\n defaultValue = this.defaultValue(key);\n\n this.set(key, defaultValue);\n return defaultValue;\n }\n };\n\n /**\n @method copy\n @return {Ember.MapWithDefault}\n @private\n */\n\n MapWithDefault.prototype.copy = function () {\n var Constructor = this.constructor;\n return copyMap(this, new Constructor({\n defaultValue: this.defaultValue\n }));\n };\n\n return MapWithDefault;\n }(Map);\n\n /**\n @module @ember/object\n */\n\n /**\n To get multiple properties at once, call `getProperties`\n with an object followed by a list of strings or an array:\n \n ```javascript\n import { getProperties } from '@ember/object';\n \n getProperties(record, 'firstName', 'lastName', 'zipCode');\n // { firstName: 'John', lastName: 'Doe', zipCode: '10011' }\n ```\n \n is equivalent to:\n \n ```javascript\n import { getProperties } from '@ember/object';\n \n getProperties(record, ['firstName', 'lastName', 'zipCode']);\n // { firstName: 'John', lastName: 'Doe', zipCode: '10011' }\n ```\n \n @method getProperties\n @static\n @for @ember/object\n @param {Object} obj\n @param {String...|Array} list of keys to get\n @return {Object}\n @public\n */\n\n\n /**\n @module @ember/object\n */\n /**\n Set a list of properties on an object. These properties are set inside\n a single `beginPropertyChanges` and `endPropertyChanges` batch, so\n observers will be buffered.\n \n ```javascript\n let anObject = Ember.Object.create();\n \n anObject.setProperties({\n firstName: 'Stanley',\n lastName: 'Stuart',\n age: 21\n });\n ```\n \n @method setProperties\n @static\n @for @ember/object\n @param obj\n @param {Object} properties\n @return properties\n @public\n */\n\n\n /**\n @module @ember/object\n */\n\n function changeEvent(keyName) {\n return keyName + ':change';\n }\n\n function beforeEvent(keyName) {\n return keyName + ':before';\n }\n\n /**\n @method addObserver\n @static\n @for @ember/object/observers\n @param obj\n @param {String} _path\n @param {Object|Function} target\n @param {Function|String} [method]\n @public\n */\n function addObserver(obj, _path, target, method) {\n addListener(obj, changeEvent(_path), target, method);\n watch(obj, _path);\n\n return this;\n }\n\n /**\n @method removeObserver\n @static\n @for @ember/object/observers\n @param obj\n @param {String} path\n @param {Object|Function} target\n @param {Function|String} [method]\n @public\n */\n function removeObserver(obj, path, target, method) {\n unwatch(obj, path);\n removeListener(obj, changeEvent(path), target, method);\n\n return this;\n }\n\n /**\n @method _addBeforeObserver\n @static\n @for @ember/object/observers\n @param obj\n @param {String} path\n @param {Object|Function} target\n @param {Function|String} [method]\n @deprecated\n @private\n */\n function _addBeforeObserver(obj, path, target, method) {\n addListener(obj, beforeEvent(path), target, method);\n watch(obj, path);\n\n return this;\n }\n\n // Suspend observer during callback.\n //\n // This should only be used by the target of the observer\n // while it is setting the observed path.\n function _suspendObserver(obj, path, target, method, callback) {\n return suspendListener(obj, changeEvent(path), target, method, callback);\n }\n\n /**\n @method removeBeforeObserver\n @static\n @for @ember/object/observers\n @param obj\n @param {String} path\n @param {Object|Function} target\n @param {Function|String} [method]\n @deprecated\n @private\n */\n function _removeBeforeObserver(obj, path, target, method) {\n unwatch(obj, path);\n removeListener(obj, beforeEvent(path), target, method);\n\n return this;\n }\n\n /**\n @module ember\n */\n\n // ..........................................................\n // BINDING\n //\n\n var Binding = function () {\n function Binding(toPath, fromPath) {\n\n // Configuration\n this._from = fromPath;\n this._to = toPath;\n this._oneWay = undefined;\n\n // State\n this._direction = undefined;\n this._readyToSync = undefined;\n this._fromObj = undefined;\n this._fromPath = undefined;\n this._toObj = undefined;\n }\n\n /**\n @class Binding\n @namespace Ember\n @deprecated See https://emberjs.com/deprecations/v2.x#toc_ember-binding\n @public\n */\n\n /**\n This copies the Binding so it can be connected to another object.\n @method copy\n @return {Ember.Binding} `this`\n @public\n */\n\n Binding.prototype.copy = function () {\n var copy = new Binding(this._to, this._from);\n if (this._oneWay) {\n copy._oneWay = true;\n }\n return copy;\n };\n\n // ..........................................................\n // CONFIG\n //\n\n /**\n This will set `from` property path to the specified value. It will not\n attempt to resolve this property path to an actual object until you\n connect the binding.\n The binding will search for the property path starting at the root object\n you pass when you `connect()` the binding. It follows the same rules as\n `get()` - see that method for more information.\n @method from\n @param {String} path The property path to connect to.\n @return {Ember.Binding} `this`\n @public\n */\n\n Binding.prototype.from = function (path) {\n this._from = path;\n return this;\n };\n\n /**\n This will set the `to` property path to the specified value. It will not\n attempt to resolve this property path to an actual object until you\n connect the binding.\n The binding will search for the property path starting at the root object\n you pass when you `connect()` the binding. It follows the same rules as\n `get()` - see that method for more information.\n @method to\n @param {String|Tuple} path A property path or tuple.\n @return {Ember.Binding} `this`\n @public\n */\n\n Binding.prototype.to = function (path) {\n this._to = path;\n return this;\n };\n\n /**\n Configures the binding as one way. A one-way binding will relay changes\n on the `from` side to the `to` side, but not the other way around. This\n means that if you change the `to` side directly, the `from` side may have\n a different value.\n @method oneWay\n @return {Ember.Binding} `this`\n @public\n */\n\n Binding.prototype.oneWay = function () {\n this._oneWay = true;\n return this;\n };\n\n /**\n @method toString\n @return {String} string representation of binding\n @public\n */\n\n Binding.prototype.toString = function () {\n var oneWay = this._oneWay ? '[oneWay]' : '';\n return 'Ember.Binding<' + emberUtils.guidFor(this) + '>(' + this._from + ' -> ' + this._to + ')' + oneWay;\n };\n\n // ..........................................................\n // CONNECT AND SYNC\n //\n\n /**\n Attempts to connect this binding instance so that it can receive and relay\n changes. This method will raise an exception if you have not set the\n from/to properties yet.\n @method connect\n @param {Object} obj The root object for this binding.\n @return {Ember.Binding} `this`\n @public\n */\n\n Binding.prototype.connect = function (obj) {\n true && !!!obj && emberDebug.assert('Must pass a valid object to Ember.Binding.connect()', !!obj);\n\n var fromObj = void 0,\n fromPath = void 0,\n possibleGlobal = void 0,\n name;\n\n // If the binding's \"from\" path could be interpreted as a global, verify\n // whether the path refers to a global or not by consulting `Ember.lookup`.\n if (isGlobalPath(this._from)) {\n name = getFirstKey(this._from);\n\n possibleGlobal = emberEnvironment.context.lookup[name];\n\n if (possibleGlobal) {\n fromObj = possibleGlobal;\n fromPath = getTailPath(this._from);\n }\n }\n\n if (fromObj === undefined) {\n fromObj = obj;\n fromPath = this._from;\n }\n\n trySet(obj, this._to, get(fromObj, fromPath));\n\n // Add an observer on the object to be notified when the binding should be updated.\n addObserver(fromObj, fromPath, this, 'fromDidChange');\n\n // If the binding is a two-way binding, also set up an observer on the target.\n if (!this._oneWay) {\n addObserver(obj, this._to, this, 'toDidChange');\n }\n\n addListener(obj, 'willDestroy', this, 'disconnect');\n\n fireDeprecations(obj, this._to, this._from, possibleGlobal, this._oneWay, !possibleGlobal && !this._oneWay);\n\n this._readyToSync = true;\n this._fromObj = fromObj;\n this._fromPath = fromPath;\n this._toObj = obj;\n\n return this;\n };\n\n /**\n Disconnects the binding instance. Changes will no longer be relayed. You\n will not usually need to call this method.\n @method disconnect\n @return {Ember.Binding} `this`\n @public\n */\n\n Binding.prototype.disconnect = function () {\n true && !!!this._toObj && emberDebug.assert('Must pass a valid object to Ember.Binding.disconnect()', !!this._toObj);\n\n // Remove an observer on the object so we're no longer notified of\n // changes that should update bindings.\n\n removeObserver(this._fromObj, this._fromPath, this, 'fromDidChange');\n\n // If the binding is two-way, remove the observer from the target as well.\n if (!this._oneWay) {\n removeObserver(this._toObj, this._to, this, 'toDidChange');\n }\n\n this._readyToSync = false; // Disable scheduled syncs...\n return this;\n };\n\n // ..........................................................\n // PRIVATE\n //\n\n /* Called when the from side changes. */\n\n Binding.prototype.fromDidChange = function () {\n this._scheduleSync('fwd');\n };\n\n /* Called when the to side changes. */\n\n Binding.prototype.toDidChange = function () {\n this._scheduleSync('back');\n };\n\n Binding.prototype._scheduleSync = function (dir) {\n var existingDir = this._direction;\n\n // If we haven't scheduled the binding yet, schedule it.\n if (existingDir === undefined) {\n run.schedule('sync', this, '_sync');\n this._direction = dir;\n }\n\n // If both a 'back' and 'fwd' sync have been scheduled on the same object,\n // default to a 'fwd' sync so that it remains deterministic.\n if (existingDir === 'back' && dir === 'fwd') {\n this._direction = 'fwd';\n }\n };\n\n Binding.prototype._sync = function () {\n var log = emberEnvironment.ENV.LOG_BINDINGS,\n fromValue,\n toValue;\n\n var toObj = this._toObj;\n\n // Don't synchronize destroyed objects or disconnected bindings.\n if (toObj.isDestroyed || !this._readyToSync) {\n return;\n }\n\n // Get the direction of the binding for the object we are\n // synchronizing from.\n var direction = this._direction;\n\n var fromObj = this._fromObj;\n var fromPath = this._fromPath;\n\n this._direction = undefined;\n\n // If we're synchronizing from the remote object...\n if (direction === 'fwd') {\n fromValue = get(fromObj, fromPath);\n\n if (log) {\n Logger.log(' ', this.toString(), '->', fromValue, fromObj);\n }\n if (this._oneWay) {\n trySet(toObj, this._to, fromValue);\n } else {\n _suspendObserver(toObj, this._to, this, 'toDidChange', function () {\n trySet(toObj, this._to, fromValue);\n });\n }\n // If we're synchronizing *to* the remote object.\n } else if (direction === 'back') {\n toValue = get(toObj, this._to);\n\n if (log) {\n Logger.log(' ', this.toString(), '<-', toValue, toObj);\n }\n _suspendObserver(fromObj, fromPath, this, 'fromDidChange', function () {\n trySet(fromObj, fromPath, toValue);\n });\n }\n };\n\n return Binding;\n }();\n\n function fireDeprecations(obj, toPath, fromPath, deprecateGlobal, deprecateOneWay, deprecateAlias) {\n\n var objectInfo = 'The `' + toPath + '` property of `' + obj + '` is an `Ember.Binding` connected to `' + fromPath + '`, but ';\n true && !!deprecateGlobal && emberDebug.deprecate(objectInfo + ('`Ember.Binding` is deprecated. Since you' + ' are binding to a global consider using a service instead.'), !deprecateGlobal, {\n id: 'ember-metal.binding',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x#toc_ember-binding'\n });\n true && !!deprecateOneWay && emberDebug.deprecate(objectInfo + ('`Ember.Binding` is deprecated. Since you' + ' are using a `oneWay` binding consider using a `readOnly` computed' + ' property instead.'), !deprecateOneWay, {\n id: 'ember-metal.binding',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x#toc_ember-binding'\n });\n true && !!deprecateAlias && emberDebug.deprecate(objectInfo + ('`Ember.Binding` is deprecated. Consider' + ' using an `alias` computed property instead.'), !deprecateAlias, {\n id: 'ember-metal.binding',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x#toc_ember-binding'\n });\n }\n\n (function (to, from) {\n for (var key in from) {\n if (from.hasOwnProperty(key)) {\n to[key] = from[key];\n }\n }\n })(Binding, {\n\n /*\n See `Ember.Binding.from`.\n @method from\n @static\n */\n from: function (from) {\n var C = this;\n return new C(undefined, from);\n },\n\n /*\n See `Ember.Binding.to`.\n @method to\n @static\n */\n to: function (to) {\n var C = this;\n return new C(to, undefined);\n }\n });\n /**\n An `Ember.Binding` connects the properties of two objects so that whenever\n the value of one property changes, the other property will be changed also.\n \n ## Automatic Creation of Bindings with `/^*Binding/`-named Properties.\n \n You do not usually create Binding objects directly but instead describe\n bindings in your class or object definition using automatic binding\n detection.\n \n Properties ending in a `Binding` suffix will be converted to `Ember.Binding`\n instances. The value of this property should be a string representing a path\n to another object or a custom binding instance created using Binding helpers\n (see \"One Way Bindings\"):\n \n ```\n valueBinding: \"MyApp.someController.title\"\n ```\n \n This will create a binding from `MyApp.someController.title` to the `value`\n property of your object instance automatically. Now the two values will be\n kept in sync.\n \n ## One Way Bindings\n \n One especially useful binding customization you can use is the `oneWay()`\n helper. This helper tells Ember that you are only interested in\n receiving changes on the object you are binding from. For example, if you\n are binding to a preference and you want to be notified if the preference\n has changed, but your object will not be changing the preference itself, you\n could do:\n \n ```\n bigTitlesBinding: Ember.Binding.oneWay(\"MyApp.preferencesController.bigTitles\")\n ```\n \n This way if the value of `MyApp.preferencesController.bigTitles` changes the\n `bigTitles` property of your object will change also. However, if you\n change the value of your `bigTitles` property, it will not update the\n `preferencesController`.\n \n One way bindings are almost twice as fast to setup and twice as fast to\n execute because the binding only has to worry about changes to one side.\n \n You should consider using one way bindings anytime you have an object that\n may be created frequently and you do not intend to change a property; only\n to monitor it for changes (such as in the example above).\n \n ## Adding Bindings Manually\n \n All of the examples above show you how to configure a custom binding, but the\n result of these customizations will be a binding template, not a fully active\n Binding instance. The binding will actually become active only when you\n instantiate the object the binding belongs to. It is useful, however, to\n understand what actually happens when the binding is activated.\n \n For a binding to function it must have at least a `from` property and a `to`\n property. The `from` property path points to the object/key that you want to\n bind from while the `to` path points to the object/key you want to bind to.\n \n When you define a custom binding, you are usually describing the property\n you want to bind from (such as `MyApp.someController.value` in the examples\n above). When your object is created, it will automatically assign the value\n you want to bind `to` based on the name of your binding key. In the\n examples above, during init, Ember objects will effectively call\n something like this on your binding:\n \n ```javascript\n binding = Ember.Binding.from(\"valueBinding\").to(\"value\");\n ```\n \n This creates a new binding instance based on the template you provide, and\n sets the to path to the `value` property of the new object. Now that the\n binding is fully configured with a `from` and a `to`, it simply needs to be\n connected to become active. This is done through the `connect()` method:\n \n ```javascript\n binding.connect(this);\n ```\n \n Note that when you connect a binding you pass the object you want it to be\n connected to. This object will be used as the root for both the from and\n to side of the binding when inspecting relative paths. This allows the\n binding to be automatically inherited by subclassed objects as well.\n \n This also allows you to bind between objects using the paths you declare in\n `from` and `to`:\n \n ```javascript\n // Example 1\n binding = Ember.Binding.from(\"App.someObject.value\").to(\"value\");\n binding.connect(this);\n \n // Example 2\n binding = Ember.Binding.from(\"parentView.value\").to(\"App.someObject.value\");\n binding.connect(this);\n ```\n \n Now that the binding is connected, it will observe both the from and to side\n and relay changes.\n \n If you ever needed to do so (you almost never will, but it is useful to\n understand this anyway), you could manually create an active binding by\n using the `Ember.bind()` helper method. (This is the same method used by\n to setup your bindings on objects):\n \n ```javascript\n Ember.bind(MyApp.anotherObject, \"value\", \"MyApp.someController.value\");\n ```\n \n Both of these code fragments have the same effect as doing the most friendly\n form of binding creation like so:\n \n ```javascript\n MyApp.anotherObject = Ember.Object.create({\n valueBinding: \"MyApp.someController.value\",\n \n // OTHER CODE FOR THIS OBJECT...\n });\n ```\n \n Ember's built in binding creation method makes it easy to automatically\n create bindings for you. You should always use the highest-level APIs\n available, even if you understand how it works underneath.\n \n @class Binding\n @namespace Ember\n @since Ember 0.9\n @public\n */\n // Ember.Binding = Binding; ES6TODO: where to put this?\n\n\n /**\n Global helper method to create a new binding. Just pass the root object\n along with a `to` and `from` path to create and connect the binding.\n \n @method bind\n @for Ember\n @param {Object} obj The root object of the transform.\n @param {String} to The path to the 'to' side of the binding.\n Must be relative to obj.\n @param {String} from The path to the 'from' side of the binding.\n Must be relative to obj or a global path.\n @return {Ember.Binding} binding instance\n @public\n */\n\n\n /**\n @module @ember/object\n */\n var a_concat = Array.prototype.concat;\n var isArray = Array.isArray;\n\n function isMethod(obj) {\n return 'function' === typeof obj && obj.isMethod !== false && obj !== Boolean && obj !== Object && obj !== Number && obj !== Array && obj !== Date && obj !== String;\n }\n\n var CONTINUE = {};\n\n function mixinProperties(mixinsMeta, mixin) {\n var guid = void 0;\n\n if (mixin instanceof Mixin) {\n guid = emberUtils.guidFor(mixin);\n if (mixinsMeta.peekMixins(guid)) {\n return CONTINUE;\n }\n mixinsMeta.writeMixins(guid, mixin);\n return mixin.properties;\n } else {\n return mixin; // apply anonymous mixin properties\n }\n }\n\n function concatenatedMixinProperties(concatProp, props, values, base) {\n // reset before adding each new mixin to pickup concats from previous\n var concats = values[concatProp] || base[concatProp];\n if (props[concatProp]) {\n concats = concats ? a_concat.call(concats, props[concatProp]) : props[concatProp];\n }\n return concats;\n }\n\n function giveDescriptorSuper(meta$$1, key, property, values, descs, base) {\n var superProperty = void 0,\n possibleDesc,\n superDesc;\n\n // Computed properties override methods, and do not call super to them\n if (values[key] === undefined) {\n // Find the original descriptor in a parent mixin\n superProperty = descs[key];\n }\n\n // If we didn't find the original descriptor in a parent mixin, find\n // it on the original object.\n if (!superProperty) {\n possibleDesc = base[key];\n superDesc = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor ? possibleDesc : undefined;\n\n\n superProperty = superDesc;\n }\n\n if (superProperty === undefined || !(superProperty instanceof ComputedProperty)) {\n return property;\n }\n\n // Since multiple mixins may inherit from the same parent, we need\n // to clone the computed property so that other mixins do not receive\n // the wrapped version.\n property = Object.create(property);\n property._getter = emberUtils.wrap(property._getter, superProperty._getter);\n if (superProperty._setter) {\n if (property._setter) {\n property._setter = emberUtils.wrap(property._setter, superProperty._setter);\n } else {\n property._setter = superProperty._setter;\n }\n }\n\n return property;\n }\n\n function giveMethodSuper(obj, key, method, values, descs) {\n var superMethod = void 0;\n\n // Methods overwrite computed properties, and do not call super to them.\n if (descs[key] === undefined) {\n // Find the original method in a parent mixin\n superMethod = values[key];\n }\n\n // If we didn't find the original value in a parent mixin, find it in\n // the original object\n superMethod = superMethod || obj[key];\n\n // Only wrap the new method if the original method was a function\n if (superMethod === undefined || 'function' !== typeof superMethod) {\n return method;\n }\n\n return emberUtils.wrap(method, superMethod);\n }\n\n function applyConcatenatedProperties(obj, key, value, values) {\n var baseValue = values[key] || obj[key];\n var ret = void 0;\n\n if (baseValue === null || baseValue === undefined) {\n ret = emberUtils.makeArray(value);\n } else if (isArray(baseValue)) {\n if (value === null || value === undefined) {\n ret = baseValue;\n } else {\n ret = a_concat.call(baseValue, value);\n }\n } else {\n ret = a_concat.call(emberUtils.makeArray(baseValue), value);\n }\n\n {\n // it is possible to use concatenatedProperties with strings (which cannot be frozen)\n // only freeze objects...\n if (typeof ret === 'object' && ret !== null) {\n // prevent mutating `concatenatedProperties` array after it is applied\n Object.freeze(ret);\n }\n }\n\n return ret;\n }\n\n function applyMergedProperties(obj, key, value, values) {\n var baseValue = values[key] || obj[key],\n propValue;\n\n true && !!isArray(value) && emberDebug.assert('You passed in `' + JSON.stringify(value) + '` as the value for `' + key + '` but `' + key + '` cannot be an Array', !isArray(value));\n\n if (!baseValue) {\n return value;\n }\n\n var newBase = emberUtils.assign({}, baseValue);\n var hasFunction = false;\n\n for (var prop in value) {\n if (!value.hasOwnProperty(prop)) {\n continue;\n }\n\n propValue = value[prop];\n\n if (isMethod(propValue)) {\n // TODO: support for Computed Properties, etc?\n hasFunction = true;\n newBase[prop] = giveMethodSuper(obj, prop, propValue, baseValue, {});\n } else {\n newBase[prop] = propValue;\n }\n }\n\n if (hasFunction) {\n newBase._super = emberUtils.ROOT;\n }\n\n return newBase;\n }\n\n function addNormalizedProperty(base, key, value, meta$$1, descs, values, concats, mergings) {\n if (value instanceof Descriptor) {\n if (value === REQUIRED && descs[key]) {\n return CONTINUE;\n }\n\n // Wrap descriptor function to implement\n // _super() if needed\n if (value._getter) {\n value = giveDescriptorSuper(meta$$1, key, value, values, descs, base);\n }\n\n descs[key] = value;\n values[key] = undefined;\n } else {\n if (concats && concats.indexOf(key) >= 0 || key === 'concatenatedProperties' || key === 'mergedProperties') {\n value = applyConcatenatedProperties(base, key, value, values);\n } else if (mergings && mergings.indexOf(key) > -1) {\n value = applyMergedProperties(base, key, value, values);\n } else if (isMethod(value)) {\n value = giveMethodSuper(base, key, value, values, descs);\n }\n\n descs[key] = undefined;\n values[key] = value;\n }\n }\n\n function mergeMixins(mixins, meta$$1, descs, values, base, keys) {\n var currentMixin = void 0,\n props = void 0,\n key = void 0,\n concats = void 0,\n mergings = void 0,\n i;\n\n function removeKeys(keyName) {\n delete descs[keyName];\n delete values[keyName];\n }\n\n for (i = 0; i < mixins.length; i++) {\n currentMixin = mixins[i];\n true && !(typeof currentMixin === 'object' && currentMixin !== null && Object.prototype.toString.call(currentMixin) !== '[object Array]') && emberDebug.assert('Expected hash or Mixin instance, got ' + Object.prototype.toString.call(currentMixin), typeof currentMixin === 'object' && currentMixin !== null && Object.prototype.toString.call(currentMixin) !== '[object Array]');\n\n props = mixinProperties(meta$$1, currentMixin);\n if (props === CONTINUE) {\n continue;\n }\n\n if (props) {\n if (base.willMergeMixin) {\n base.willMergeMixin(props);\n }\n concats = concatenatedMixinProperties('concatenatedProperties', props, values, base);\n mergings = concatenatedMixinProperties('mergedProperties', props, values, base);\n\n for (key in props) {\n if (!props.hasOwnProperty(key)) {\n continue;\n }\n keys.push(key);\n addNormalizedProperty(base, key, props[key], meta$$1, descs, values, concats, mergings);\n }\n\n // manually copy toString() because some JS engines do not enumerate it\n if (props.hasOwnProperty('toString')) {\n base.toString = props.toString;\n }\n } else if (currentMixin.mixins) {\n mergeMixins(currentMixin.mixins, meta$$1, descs, values, base, keys);\n if (currentMixin._without) {\n currentMixin._without.forEach(removeKeys);\n }\n }\n }\n }\n\n function detectBinding(key) {\n var length = key.length;\n\n return length > 7 && key.charCodeAt(length - 7) === 66 && key.indexOf('inding', length - 6) !== -1;\n }\n // warm both paths of above function\n detectBinding('notbound');\n detectBinding('fooBinding');\n\n function connectBindings(obj, meta$$1) {\n // TODO Mixin.apply(instance) should disconnect binding if exists\n meta$$1.forEachBindings(function (key, binding) {\n var to;\n\n if (binding) {\n to = key.slice(0, -7); // strip Binding off end\n\n if (binding instanceof Binding) {\n binding = binding.copy(); // copy prototypes' instance\n binding.to(to);\n } else {\n // binding is string path\n binding = new Binding(to, binding);\n }\n binding.connect(obj);\n obj[key] = binding;\n }\n });\n // mark as applied\n meta$$1.clearBindings();\n }\n\n function finishPartial(obj, meta$$1) {\n connectBindings(obj, meta$$1 === undefined ? meta(obj) : meta$$1);\n return obj;\n }\n\n function followAlias(obj, desc, descs, values) {\n var altKey = desc.methodName;\n var value = void 0;\n var possibleDesc = void 0;\n if (descs[altKey] || values[altKey]) {\n value = values[altKey];\n desc = descs[altKey];\n } else if ((possibleDesc = obj[altKey]) && possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor) {\n desc = possibleDesc;\n value = undefined;\n } else {\n desc = undefined;\n value = obj[altKey];\n }\n\n return { desc: desc, value: value };\n }\n\n function updateObserversAndListeners(obj, key, paths, updateMethod) {\n var i;\n\n if (paths) {\n for (i = 0; i < paths.length; i++) {\n updateMethod(obj, paths[i], null, key);\n }\n }\n }\n\n function replaceObserversAndListeners(obj, key, observerOrListener) {\n var prev = obj[key];\n\n if (typeof prev === 'function') {\n updateObserversAndListeners(obj, key, prev.__ember_observesBefore__, _removeBeforeObserver);\n updateObserversAndListeners(obj, key, prev.__ember_observes__, removeObserver);\n updateObserversAndListeners(obj, key, prev.__ember_listens__, removeListener);\n }\n\n if (typeof observerOrListener === 'function') {\n updateObserversAndListeners(obj, key, observerOrListener.__ember_observesBefore__, _addBeforeObserver);\n updateObserversAndListeners(obj, key, observerOrListener.__ember_observes__, addObserver);\n updateObserversAndListeners(obj, key, observerOrListener.__ember_listens__, addListener);\n }\n }\n\n function applyMixin(obj, mixins, partial) {\n var descs = {},\n i,\n followed;\n var values = {};\n var meta$$1 = meta(obj);\n var keys = [];\n var key = void 0,\n value = void 0,\n desc = void 0;\n\n obj._super = emberUtils.ROOT;\n\n // Go through all mixins and hashes passed in, and:\n //\n // * Handle concatenated properties\n // * Handle merged properties\n // * Set up _super wrapping if necessary\n // * Set up computed property descriptors\n // * Copying `toString` in broken browsers\n mergeMixins(mixins, meta$$1, descs, values, obj, keys);\n\n for (i = 0; i < keys.length; i++) {\n key = keys[i];\n if (key === 'constructor' || !values.hasOwnProperty(key)) {\n continue;\n }\n\n desc = descs[key];\n value = values[key];\n\n if (desc === REQUIRED) {\n continue;\n }\n\n while (desc && desc instanceof Alias) {\n followed = followAlias(obj, desc, descs, values);\n\n desc = followed.desc;\n value = followed.value;\n }\n\n if (desc === undefined && value === undefined) {\n continue;\n }\n\n replaceObserversAndListeners(obj, key, value);\n\n if (detectBinding(key)) {\n meta$$1.writeBindings(key, value);\n }\n\n defineProperty(obj, key, desc, value, meta$$1);\n }\n\n if (!partial) {\n // don't apply to prototype\n finishPartial(obj, meta$$1);\n }\n\n return obj;\n }\n\n /**\n @method mixin\n @param obj\n @param mixins*\n @return obj\n @private\n */\n\n\n /**\n The `Mixin` class allows you to create mixins, whose properties can be\n added to other classes. For instance,\n \n ```javascript\n import Mixin from '@ember/object/mixin';\n \n const EditableMixin = Mixin.create({\n edit() {\n console.log('starting to edit');\n this.set('isEditing', true);\n },\n isEditing: false\n });\n ```\n \n ```javascript\n import EmberObject from '@ember/object';\n import EditableMixin from '../mixins/editable';\n \n // Mix mixins into classes by passing them as the first arguments to\n // `.extend.`\n const Comment = EmberObject.extend(EditableMixin, {\n post: null\n });\n \n let comment = Comment.create({\n post: somePost\n });\n \n comment.edit(); // outputs 'starting to edit'\n ```\n \n Note that Mixins are created with `Mixin.create`, not\n `Mixin.extend`.\n \n Note that mixins extend a constructor's prototype so arrays and object literals\n defined as properties will be shared amongst objects that implement the mixin.\n If you want to define a property in a mixin that is not shared, you can define\n it either as a computed property or have it be created on initialization of the object.\n \n ```javascript\n // filters array will be shared amongst any object implementing mixin\n import Mixin from '@ember/object/mixin';\n import { A } from '@ember/array';\n \n const FilterableMixin = Mixin.create({\n filters: A()\n });\n ```\n \n ```javascript\n import Mixin from '@ember/object/mixin';\n import { A } from '@ember/array';\n import { computed } from '@ember/object';\n \n // filters will be a separate array for every object implementing the mixin\n const FilterableMixin = Mixin.create({\n filters: computed(function() {\n return A();\n })\n });\n ```\n \n ```javascript\n import Mixin from '@ember/object/mixin';\n import { A } from '@ember/array';\n \n // filters will be created as a separate array during the object's initialization\n const Filterable = Mixin.create({\n filters: null,\n \n init() {\n this._super(...arguments);\n this.set(\"filters\", A());\n }\n });\n ```\n \n @class Mixin\n @public\n */\n\n var Mixin = function () {\n function Mixin(mixins, properties) {\n\n this.properties = properties;\n\n var length = mixins && mixins.length,\n m,\n i,\n x;\n\n if (length > 0) {\n m = new Array(length);\n\n\n for (i = 0; i < length; i++) {\n x = mixins[i];\n\n if (x instanceof Mixin) {\n m[i] = x;\n } else {\n m[i] = new Mixin(undefined, x);\n }\n }\n\n this.mixins = m;\n } else {\n this.mixins = undefined;\n }\n this.ownerConstructor = undefined;\n this._without = undefined;\n this[emberUtils.GUID_KEY] = null;\n this[emberUtils.NAME_KEY] = null;\n emberDebug.debugSeal(this);\n }\n\n Mixin.applyPartial = function (obj) {\n var _len2, args, _key2;\n\n for (_len2 = arguments.length, args = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {\n args[_key2 - 1] = arguments[_key2];\n }\n\n return applyMixin(obj, args, true);\n };\n\n /**\n @method create\n @for @ember/object/mixin\n @static\n @param arguments*\n @public\n */\n\n Mixin.create = function () {\n // ES6TODO: this relies on a global state?\n unprocessedFlag = true;\n var M = this,\n _len3,\n args,\n _key3;\n\n for (_len3 = arguments.length, args = Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {\n args[_key3] = arguments[_key3];\n }\n\n return new M(args, undefined);\n };\n\n // returns the mixins currently applied to the specified object\n // TODO: Make `mixin`\n\n\n Mixin.mixins = function (obj) {\n var meta$$1 = exports.peekMeta(obj);\n var ret = [];\n if (meta$$1 === undefined) {\n return ret;\n }\n\n meta$$1.forEachMixins(function (key, currentMixin) {\n // skip primitive mixins since these are always anonymous\n if (!currentMixin.properties) {\n ret.push(currentMixin);\n }\n });\n\n return ret;\n };\n\n /**\n @method reopen\n @param arguments*\n @private\n */\n\n Mixin.prototype.reopen = function () {\n var currentMixin = void 0;\n\n if (this.properties) {\n currentMixin = new Mixin(undefined, this.properties);\n this.properties = undefined;\n this.mixins = [currentMixin];\n } else if (!this.mixins) {\n this.mixins = [];\n }\n\n var mixins = this.mixins;\n var idx = void 0;\n\n for (idx = 0; idx < arguments.length; idx++) {\n currentMixin = arguments[idx];\n true && !(typeof currentMixin === 'object' && currentMixin !== null && Object.prototype.toString.call(currentMixin) !== '[object Array]') && emberDebug.assert('Expected hash or Mixin instance, got ' + Object.prototype.toString.call(currentMixin), typeof currentMixin === 'object' && currentMixin !== null && Object.prototype.toString.call(currentMixin) !== '[object Array]');\n\n if (currentMixin instanceof Mixin) {\n mixins.push(currentMixin);\n } else {\n mixins.push(new Mixin(undefined, currentMixin));\n }\n }\n\n return this;\n };\n\n /**\n @method apply\n @param obj\n @return applied object\n @private\n */\n\n Mixin.prototype.apply = function (obj) {\n return applyMixin(obj, [this], false);\n };\n\n Mixin.prototype.applyPartial = function (obj) {\n return applyMixin(obj, [this], true);\n };\n\n /**\n @method detect\n @param obj\n @return {Boolean}\n @private\n */\n\n Mixin.prototype.detect = function (obj) {\n if (typeof obj !== 'object' || obj === null) {\n return false;\n }\n if (obj instanceof Mixin) {\n return _detect(obj, this, {});\n }\n var meta$$1 = exports.peekMeta(obj);\n if (meta$$1 === undefined) {\n return false;\n }\n return !!meta$$1.peekMixins(emberUtils.guidFor(this));\n };\n\n Mixin.prototype.without = function () {\n var ret = new Mixin([this]),\n _len4,\n args,\n _key4;\n\n for (_len4 = arguments.length, args = Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {\n args[_key4] = arguments[_key4];\n }\n\n ret._without = args;\n return ret;\n };\n\n Mixin.prototype.keys = function () {\n var keys = {};\n\n\n _keys(keys, this, {});\n var ret = Object.keys(keys);\n return ret;\n };\n\n return Mixin;\n }();\n\n Mixin._apply = applyMixin;\n Mixin.finishPartial = finishPartial;\n\n var MixinPrototype = Mixin.prototype;\n MixinPrototype.toString = Object.toString;\n\n emberDebug.debugSeal(MixinPrototype);\n\n var unprocessedFlag = false;\n\n function _detect(curMixin, targetMixin, seen) {\n var guid = emberUtils.guidFor(curMixin);\n\n if (seen[guid]) {\n return false;\n }\n seen[guid] = true;\n\n if (curMixin === targetMixin) {\n return true;\n }\n var mixins = curMixin.mixins;\n var loc = mixins ? mixins.length : 0;\n while (--loc >= 0) {\n if (_detect(mixins[loc], targetMixin, seen)) {\n return true;\n }\n }\n return false;\n }\n\n function _keys(ret, mixin, seen) {\n var props, i, key;\n\n if (seen[emberUtils.guidFor(mixin)]) {\n return;\n }\n seen[emberUtils.guidFor(mixin)] = true;\n\n if (mixin.properties) {\n props = Object.keys(mixin.properties);\n\n for (i = 0; i < props.length; i++) {\n key = props[i];\n\n ret[key] = true;\n }\n } else if (mixin.mixins) {\n mixin.mixins.forEach(function (x) {\n return _keys(ret, x, seen);\n });\n }\n }\n\n var REQUIRED = new Descriptor();\n REQUIRED.toString = function () {\n return '(Required Property)';\n };\n\n /**\n Denotes a required property for a mixin\n \n @method required\n @for Ember\n @private\n */\n\n\n function Alias(methodName) {\n this.isDescriptor = true;\n this.methodName = methodName;\n }\n\n Alias.prototype = new Descriptor();\n\n /**\n Makes a method available via an additional name.\n \n ```app/utils/person.js\n import EmberObject, {\n aliasMethod\n } from '@ember/object';\n \n export default EmberObject.extend({\n name() {\n return 'Tomhuda Katzdale';\n },\n moniker: aliasMethod('name')\n });\n ```\n \n ```javascript\n let goodGuy = Person.create();\n \n goodGuy.name(); // 'Tomhuda Katzdale'\n goodGuy.moniker(); // 'Tomhuda Katzdale'\n ```\n \n @method aliasMethod\n @static\n @for @ember/object\n @param {String} methodName name of the method to alias\n @public\n */\n\n\n // ..........................................................\n // OBSERVER HELPER\n //\n\n /**\n Specify a method that observes property changes.\n \n ```javascript\n import EmberObject from '@ember/object';\n import { observer } from '@ember/object';\n \n export default EmberObject.extend({\n valueObserver: observer('value', function() {\n // Executes whenever the \"value\" property changes\n })\n });\n ```\n \n Also available as `Function.prototype.observes` if prototype extensions are\n enabled.\n \n @method observer\n @for @ember/object\n @param {String} propertyNames*\n @param {Function} func\n @return func\n @public\n @static\n */\n function observer() {\n var _paths = void 0,\n func = void 0,\n _len5,\n args,\n _key5,\n i;\n\n for (_len5 = arguments.length, args = Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {\n args[_key5] = arguments[_key5];\n }\n\n if (typeof args[args.length - 1] !== 'function') {\n // revert to old, soft-deprecated argument ordering\n true && !false && emberDebug.deprecate('Passing the dependentKeys after the callback function in observer is deprecated. Ensure the callback function is the last argument.', false, { id: 'ember-metal.observer-argument-order', until: '3.0.0' });\n\n func = args.shift();\n _paths = args;\n } else {\n func = args.pop();\n _paths = args;\n }\n\n true && !(typeof func === 'function') && emberDebug.assert('observer called without a function', typeof func === 'function');\n true && !(_paths.length > 0 && _paths.every(function (p) {\n return typeof p === 'string' && p.length;\n })) && emberDebug.assert('observer called without valid path', _paths.length > 0 && _paths.every(function (p) {\n return typeof p === 'string' && p.length;\n }));\n\n var paths = [];\n var addWatchedProperty = function (path) {\n return paths.push(path);\n };\n\n for (i = 0; i < _paths.length; ++i) {\n expandProperties(_paths[i], addWatchedProperty);\n }\n\n func.__ember_observes__ = paths;\n return func;\n }\n\n /**\n Specify a method that observes property changes.\n \n ```javascript\n import EmberObject from '@ember/object';\n \n EmberObject.extend({\n valueObserver: Ember.immediateObserver('value', function() {\n // Executes whenever the \"value\" property changes\n })\n });\n ```\n \n In the future, `observer` may become asynchronous. In this event,\n `immediateObserver` will maintain the synchronous behavior.\n \n Also available as `Function.prototype.observesImmediately` if prototype extensions are\n enabled.\n \n @method _immediateObserver\n @for Ember\n @param {String} propertyNames*\n @param {Function} func\n @deprecated Use `observer` instead.\n @return func\n @private\n */\n\n\n /**\n When observers fire, they are called with the arguments `obj`, `keyName`.\n \n Note, `@each.property` observer is called per each add or replace of an element\n and it's not called with a specific enumeration item.\n \n A `_beforeObserver` fires before a property changes.\n \n @method beforeObserver\n @for Ember\n @param {String} propertyNames*\n @param {Function} func\n @return func\n @deprecated\n @private\n */\n\n\n /**\n @module ember\n @private\n */\n\n /**\n Read-only property that returns the result of a container lookup.\n \n @class InjectedProperty\n @namespace Ember\n @constructor\n @param {String} type The container type the property will lookup\n @param {String} name (optional) The name the property will lookup, defaults\n to the property's name\n @private\n */\n function InjectedProperty(type, name) {\n this.type = type;\n this.name = name;\n\n this._super$Constructor(injectedPropertyGet);\n AliasedPropertyPrototype.oneWay.call(this);\n }\n\n function injectedPropertyGet(keyName) {\n var desc = this[keyName];\n var owner = emberUtils.getOwner(this) || this.container; // fallback to `container` for backwards compat\n\n true && !(desc && desc.isDescriptor && desc.type) && emberDebug.assert('InjectedProperties should be defined with the inject computed property macros.', desc && desc.isDescriptor && desc.type);\n true && !owner && emberDebug.assert('Attempting to lookup an injected property on an object without a container, ensure that the object was instantiated via a container.', owner);\n\n return owner.lookup(desc.type + ':' + (desc.name || keyName));\n }\n\n InjectedProperty.prototype = Object.create(Descriptor.prototype);\n\n var InjectedPropertyPrototype = InjectedProperty.prototype;\n var ComputedPropertyPrototype$1 = ComputedProperty.prototype;\n var AliasedPropertyPrototype = AliasedProperty.prototype;\n\n InjectedPropertyPrototype._super$Constructor = ComputedProperty;\n\n InjectedPropertyPrototype.get = ComputedPropertyPrototype$1.get;\n InjectedPropertyPrototype.readOnly = ComputedPropertyPrototype$1.readOnly;\n InjectedPropertyPrototype.teardown = ComputedPropertyPrototype$1.teardown;\n\n var splice = Array.prototype.splice;\n\n /**\n A wrapper for a native ES5 descriptor. In an ideal world, we wouldn't need\n this at all, however, the way we currently flatten/merge our mixins require\n a special value to denote a descriptor.\n \n @class Descriptor\n @private\n */\n\n var Descriptor$1 = function (_EmberDescriptor) {\n emberBabel.inherits(Descriptor$$1, _EmberDescriptor);\n\n function Descriptor$$1(desc) {\n\n var _this = emberBabel.possibleConstructorReturn(this, _EmberDescriptor.call(this));\n\n _this.desc = desc;\n return _this;\n }\n\n Descriptor$$1.prototype.setup = function (obj, key) {\n Object.defineProperty(obj, key, this.desc);\n };\n\n Descriptor$$1.prototype.teardown = function () {};\n\n return Descriptor$$1;\n }(Descriptor);\n\n exports['default'] = Ember;\n exports.computed = function () {\n for (_len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var func = args.pop(),\n _len,\n args,\n _key;\n\n var cp = new ComputedProperty(func);\n\n if (args.length > 0) {\n cp.property.apply(cp, args);\n }\n\n return cp;\n };\n exports.cacheFor = cacheFor;\n exports.ComputedProperty = ComputedProperty;\n exports.alias = function (altKey) {\n return new AliasedProperty(altKey);\n };\n exports.merge = function (original, updates) {\n if (updates === null || typeof updates !== 'object') {\n return original;\n }\n\n var props = Object.keys(updates),\n i;\n var prop = void 0;\n\n for (i = 0; i < props.length; i++) {\n prop = props[i];\n original[prop] = updates[prop];\n }\n\n return original;\n };\n exports.deprecateProperty = function (object, deprecatedKey, newKey, options) {\n function _deprecate() {\n true && !false && emberDebug.deprecate('Usage of `' + deprecatedKey + '` is deprecated, use `' + newKey + '` instead.', false, options);\n }\n\n Object.defineProperty(object, deprecatedKey, {\n configurable: true,\n enumerable: false,\n set: function (value) {\n _deprecate();\n set(this, newKey, value);\n },\n get: function () {\n _deprecate();\n return get(this, newKey);\n }\n });\n };\n exports.instrument = instrument;\n exports._instrumentStart = _instrumentStart;\n exports.instrumentationReset = function () {\n subscribers.length = 0;\n cache = {};\n };\n exports.instrumentationSubscribe = function (pattern, object) {\n var paths = pattern.split('.'),\n i;\n var path = void 0;\n var regex = [];\n\n for (i = 0; i < paths.length; i++) {\n path = paths[i];\n if (path === '*') {\n regex.push('[^\\\\.]*');\n } else {\n regex.push(path);\n }\n }\n\n regex = regex.join('\\\\.');\n regex = regex + '(\\\\..*)?';\n\n var subscriber = {\n pattern: pattern,\n regex: new RegExp('^' + regex + '$'),\n object: object\n };\n\n subscribers.push(subscriber);\n cache = {};\n\n return subscriber;\n };\n exports.instrumentationUnsubscribe = function (subscriber) {\n var index = void 0,\n i;\n\n for (i = 0; i < subscribers.length; i++) {\n if (subscribers[i] === subscriber) {\n index = i;\n }\n }\n\n subscribers.splice(index, 1);\n cache = {};\n };\n exports.getOnerror = function () {\n return onerror;\n };\n exports.setOnerror = function (handler) {\n onerror = handler;\n };\n exports.setDispatchOverride = function (handler) {\n dispatchOverride = handler;\n };\n exports.getDispatchOverride = function () {\n return dispatchOverride;\n };\n exports.META_DESC = META_DESC;\n exports.meta = meta;\n exports.deleteMeta = function (obj) {\n {\n counters.deleteCalls++;\n }\n\n var meta = exports.peekMeta(obj);\n if (meta !== undefined) {\n meta.destroy();\n }\n };\n exports.Cache = Cache;\n exports._getPath = _getPath;\n exports.get = get;\n exports.getWithDefault = function (root, key, defaultValue) {\n var value = get(root, key);\n\n if (value === undefined) {\n return defaultValue;\n }\n return value;\n };\n exports.set = set;\n exports.trySet = trySet;\n exports.WeakMap = WeakMap$1;\n exports.WeakMapPolyfill = WeakMapPolyfill;\n exports.addListener = addListener;\n exports.hasListeners = function (obj, eventName) {\n var meta$$1 = exports.peekMeta(obj);\n if (meta$$1 === undefined) {\n return false;\n }\n var matched = meta$$1.matchingListeners(eventName);\n return matched !== undefined && matched.length > 0;\n };\n exports.listenersFor = listenersFor;\n exports.on = function () {\n for (_len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var func = args.pop(),\n _len,\n args,\n _key;\n var events = args;\n\n true && !(typeof func === 'function') && emberDebug.assert('on expects function as last argument', typeof func === 'function');\n true && !(events.length > 0 && events.every(function (p) {\n return typeof p === 'string' && p.length;\n })) && emberDebug.assert('on called without valid event names', events.length > 0 && events.every(function (p) {\n return typeof p === 'string' && p.length;\n }));\n\n func.__ember_listens__ = events;\n return func;\n };\n exports.removeListener = removeListener;\n exports.sendEvent = sendEvent;\n exports.suspendListener = suspendListener;\n exports.suspendListeners = suspendListeners;\n exports.watchedEvents = function (obj) {\n var meta$$1 = exports.peekMeta(obj);\n return meta$$1 !== undefined ? meta$$1.watchedEvents() : [];\n };\n exports.isNone = isNone;\n exports.isEmpty = isEmpty;\n exports.isBlank = isBlank;\n exports.isPresent = function (obj) {\n return !isBlank(obj);\n };\n exports.run = run;\n exports.ObserverSet = ObserverSet;\n exports.beginPropertyChanges = beginPropertyChanges;\n exports.changeProperties = changeProperties;\n exports.endPropertyChanges = endPropertyChanges;\n exports.overrideChains = overrideChains;\n exports.propertyDidChange = propertyDidChange;\n exports.propertyWillChange = propertyWillChange;\n exports.PROPERTY_DID_CHANGE = PROPERTY_DID_CHANGE;\n exports.defineProperty = defineProperty;\n exports.Descriptor = Descriptor;\n exports._hasCachedComputedProperties = function () {\n hasCachedComputedProperties = true;\n };\n exports.watchKey = watchKey;\n exports.unwatchKey = unwatchKey;\n exports.ChainNode = ChainNode;\n exports.finishChains = function (meta$$1) {\n // finish any current chains node watchers that reference obj\n var chainWatchers = meta$$1.readableChainWatchers();\n if (chainWatchers !== undefined) {\n chainWatchers.revalidateAll();\n }\n // ensure that if we have inherited any chains they have been\n // copied onto our own meta.\n if (meta$$1.readableChains() !== undefined) {\n meta$$1.writableChains(makeChainNode);\n }\n };\n exports.removeChainWatcher = removeChainWatcher;\n exports.watchPath = watchPath;\n exports.unwatchPath = unwatchPath;\n exports.isWatching = function (obj, key) {\n return watcherCount(obj, key) > 0;\n };\n exports.unwatch = unwatch;\n exports.watch = watch;\n exports.watcherCount = watcherCount;\n exports.libraries = libraries;\n exports.Libraries = Libraries;\n exports.Map = Map;\n exports.MapWithDefault = MapWithDefault;\n exports.OrderedSet = OrderedSet;\n exports.getProperties = function (obj) {\n var ret = {};\n var propertyNames = arguments;\n var i = 1;\n\n if (arguments.length === 2 && Array.isArray(arguments[1])) {\n i = 0;\n propertyNames = arguments[1];\n }\n for (; i < propertyNames.length; i++) {\n ret[propertyNames[i]] = get(obj, propertyNames[i]);\n }\n return ret;\n };\n exports.setProperties = function (obj, properties) {\n if (properties === null || typeof properties !== 'object') {\n return properties;\n }\n changeProperties(function () {\n var props = Object.keys(properties),\n i;\n var propertyName = void 0;\n\n for (i = 0; i < props.length; i++) {\n propertyName = props[i];\n\n set(obj, propertyName, properties[propertyName]);\n }\n });\n return properties;\n };\n exports.expandProperties = expandProperties;\n exports._suspendObserver = _suspendObserver;\n exports._suspendObservers = function (obj, paths, target, method, callback) {\n var events = paths.map(changeEvent);\n return suspendListeners(obj, events, target, method, callback);\n };\n exports.addObserver = addObserver;\n exports.observersFor = function (obj, path) {\n return listenersFor(obj, changeEvent(path));\n };\n exports.removeObserver = removeObserver;\n exports._addBeforeObserver = _addBeforeObserver;\n exports._removeBeforeObserver = _removeBeforeObserver;\n exports.Mixin = Mixin;\n exports.aliasMethod = function (methodName) {\n return new Alias(methodName);\n };\n exports._immediateObserver = function () {\n var i, arg;\n\n true && !false && emberDebug.deprecate('Usage of `Ember.immediateObserver` is deprecated, use `observer` instead.', false, { id: 'ember-metal.immediate-observer', until: '3.0.0' });\n\n for (i = 0; i < arguments.length; i++) {\n arg = arguments[i];\n\n true && !(typeof arg !== 'string' || arg.indexOf('.') === -1) && emberDebug.assert('Immediate observers must observe internal properties only, not properties on other objects.', typeof arg !== 'string' || arg.indexOf('.') === -1);\n }\n\n return observer.apply(this, arguments);\n };\n exports._beforeObserver = function () {\n for (_len6 = arguments.length, args = Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {\n args[_key6] = arguments[_key6];\n }\n\n var func = args[args.length - 1],\n _len6,\n args,\n _key6,\n i;\n var paths = void 0;\n\n var addWatchedProperty = function (path) {\n paths.push(path);\n };\n\n var _paths = args.slice(0, -1);\n\n if (typeof func !== 'function') {\n // revert to old, soft-deprecated argument ordering\n\n func = args[0];\n _paths = args.slice(1);\n }\n\n paths = [];\n\n for (i = 0; i < _paths.length; ++i) {\n expandProperties(_paths[i], addWatchedProperty);\n }\n\n if (typeof func !== 'function') {\n throw new emberDebug.EmberError('_beforeObserver called without a function');\n }\n\n func.__ember_observesBefore__ = paths;\n return func;\n };\n exports.mixin = function (obj) {\n var _len, args, _key;\n\n for (_len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n applyMixin(obj, args, false);\n return obj;\n };\n exports.observer = observer;\n exports.required = function () {\n true && !false && emberDebug.deprecate('Ember.required is deprecated as its behavior is inconsistent and unreliable.', false, { id: 'ember-metal.required', until: '3.0.0' });\n\n return REQUIRED;\n };\n exports.REQUIRED = REQUIRED;\n exports.hasUnprocessedMixins = function () {\n return unprocessedFlag;\n };\n exports.clearUnprocessedMixins = function () {\n unprocessedFlag = false;\n };\n exports.detectBinding = detectBinding;\n exports.Binding = Binding;\n exports.bind = function (obj, to, from) {\n return new Binding(to, from).connect(obj);\n };\n exports.isGlobalPath = isGlobalPath;\n exports.InjectedProperty = InjectedProperty;\n exports.setHasViews = function (fn) {\n hasViews = fn;\n };\n exports.tagForProperty = function (object, propertyKey, _meta) {\n if (typeof object !== 'object' || object === null) {\n return _glimmer_reference.CONSTANT_TAG;\n }\n\n var meta$$1 = _meta === undefined ? meta(object) : _meta;\n if (meta$$1.isProxy()) {\n return tagFor(object, meta$$1);\n }\n\n var tags = meta$$1.writableTags();\n var tag = tags[propertyKey];\n if (tag) {\n return tag;\n }\n\n return tags[propertyKey] = makeTag();\n };\n exports.tagFor = tagFor;\n exports.markObjectAsDirty = markObjectAsDirty;\n exports.replace = function (array, idx, amt, objects) {\n var args = [].concat(objects);\n var ret = [];\n // https://code.google.com/p/chromium/issues/detail?id=56588\n var size = 60000;\n var start = idx;\n var ends = amt;\n var count = void 0,\n chunk = void 0;\n\n while (args.length) {\n count = ends > size ? size : ends;\n if (count <= 0) {\n count = 0;\n }\n\n chunk = args.splice(0, size);\n chunk = [start, count].concat(chunk);\n\n start += size;\n ends -= count;\n\n ret = ret.concat(splice.apply(array, chunk));\n }\n return ret;\n };\n exports.isProxy = function (value) {\n var meta$$1;\n\n if (typeof value === 'object' && value !== null) {\n meta$$1 = exports.peekMeta(value);\n\n return meta$$1 === undefined ? false : meta$$1.isProxy();\n }\n\n return false;\n };\n exports.descriptor = function (desc) {\n return new Descriptor$1(desc);\n };\n\n Object.defineProperty(exports, '__esModule', { value: true });\n});","enifed('ember-template-compiler/compat', ['ember-metal', 'ember-template-compiler/system/precompile', 'ember-template-compiler/system/compile', 'ember-template-compiler/system/compile-options'], function (_emberMetal, _precompile, _compile, _compileOptions) {\n 'use strict';\n\n var EmberHandlebars = _emberMetal.default.Handlebars = _emberMetal.default.Handlebars || {}; // reexports\n\n var EmberHTMLBars = _emberMetal.default.HTMLBars = _emberMetal.default.HTMLBars || {};\n\n EmberHTMLBars.precompile = EmberHandlebars.precompile = _precompile.default;\n EmberHTMLBars.compile = EmberHandlebars.compile = _compile.default;\n EmberHTMLBars.registerPlugin = _compileOptions.registerPlugin;\n});","enifed('ember-template-compiler/index', ['exports', 'ember-template-compiler/system/precompile', 'ember-template-compiler/system/compile', 'ember-template-compiler/system/compile-options', 'ember-template-compiler/plugins', 'ember-metal', 'ember/features', 'ember-environment', 'ember/version', 'ember-template-compiler/compat', 'ember-template-compiler/system/bootstrap'], function (exports, _precompile, _compile, _compileOptions, _plugins, _emberMetal, _features, _emberEnvironment, _version) {\n 'use strict';\n\n exports.defaultPlugins = exports.registerPlugin = exports.compileOptions = exports.compile = exports.precompile = exports._Ember = undefined;\n Object.defineProperty(exports, 'precompile', {\n enumerable: true,\n get: function () {\n return _precompile.default;\n }\n });\n Object.defineProperty(exports, 'compile', {\n enumerable: true,\n get: function () {\n return _compile.default;\n }\n });\n Object.defineProperty(exports, 'compileOptions', {\n enumerable: true,\n get: function () {\n return _compileOptions.default;\n }\n });\n Object.defineProperty(exports, 'registerPlugin', {\n enumerable: true,\n get: function () {\n return _compileOptions.registerPlugin;\n }\n });\n Object.defineProperty(exports, 'defaultPlugins', {\n enumerable: true,\n get: function () {\n return _plugins.default;\n }\n });\n\n // private API used by ember-cli-htmlbars to setup ENV and FEATURES\n if (!_emberMetal.default.ENV) {\n _emberMetal.default.ENV = _emberEnvironment.ENV;\n }\n if (!_emberMetal.default.FEATURES) {\n _emberMetal.default.FEATURES = _features.FEATURES;\n }\n if (!_emberMetal.default.VERSION) {\n _emberMetal.default.VERSION = _version.default;\n }\n\n exports._Ember = _emberMetal.default;\n});","enifed('ember-template-compiler/plugins/assert-input-helper-without-block', ['exports', 'ember-debug', 'ember-template-compiler/system/calculate-location-display'], function (exports, _emberDebug, _calculateLocationDisplay) {\n 'use strict';\n\n exports.default = function (env) {\n var moduleName = env.meta.moduleName;\n\n return {\n name: 'assert-input-helper-without-block',\n\n visitors: {\n BlockStatement: function (node) {\n if (node.path.original !== 'input') {\n return;\n }\n\n true && !false && (0, _emberDebug.assert)(assertMessage(moduleName, node));\n }\n }\n };\n };\n\n\n function assertMessage(moduleName, node) {\n var sourceInformation = (0, _calculateLocationDisplay.default)(moduleName, node.loc);\n\n return 'The {{input}} helper cannot be used in block form. ' + sourceInformation;\n }\n});","enifed('ember-template-compiler/plugins/assert-reserved-named-arguments', ['exports', 'ember-debug', 'ember-template-compiler/system/calculate-location-display'], function (exports, _emberDebug, _calculateLocationDisplay) {\n 'use strict';\n\n exports.default = function (env) {\n var moduleName = env.meta.moduleName;\n\n return {\n name: 'assert-reserved-named-arguments',\n\n visitors: {\n PathExpression: function (node) {\n if (node.original[0] === '@') {\n true && !false && (0, _emberDebug.assert)(assertMessage(moduleName, node));\n }\n }\n }\n };\n };\n\n\n function assertMessage(moduleName, node) {\n var path = node.original;\n var source = (0, _calculateLocationDisplay.default)(moduleName, node.loc);\n\n return '\\'' + path + '\\' is not a valid path. ' + source;\n }\n});","enifed('ember-template-compiler/plugins/deprecate-render-model', ['exports', 'ember-debug', 'ember-template-compiler/system/calculate-location-display'], function (exports, _emberDebug, _calculateLocationDisplay) {\n 'use strict';\n\n exports.default = function (env) {\n var moduleName = env.meta.moduleName;\n\n return {\n name: 'deprecate-render-model',\n\n visitors: {\n MustacheStatement: function (node) {\n if (node.path.original === 'render' && node.params.length > 1) {\n node.params.forEach(function (param) {\n if (param.type !== 'PathExpression') {\n return;\n }\n\n true && !false && (0, _emberDebug.deprecate)(deprecationMessage(moduleName, node, param), false, {\n id: 'ember-template-compiler.deprecate-render-model',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x#toc_model-param-in-code-render-code-helper'\n });\n });\n }\n }\n }\n };\n };\n\n\n function deprecationMessage(moduleName, node, param) {\n var sourceInformation = (0, _calculateLocationDisplay.default)(moduleName, node.loc);\n var componentName = node.params[0].original;\n var modelName = param.original;\n\n\n return 'Please refactor `' + ('{{render \"' + componentName + '\" ' + modelName + '}}') + '` to a component and invoke via' + (' `' + ('{{' + componentName + ' model=' + modelName + '}}') + '`. ' + sourceInformation);\n }\n});","enifed('ember-template-compiler/plugins/deprecate-render', ['exports', 'ember-debug', 'ember-template-compiler/system/calculate-location-display'], function (exports, _emberDebug, _calculateLocationDisplay) {\n 'use strict';\n\n exports.default = function (env) {\n var moduleName = env.meta.moduleName;\n\n return {\n name: 'deprecate-render',\n\n visitors: {\n MustacheStatement: function (node) {\n if (node.path.original !== 'render') {\n return;\n }\n if (node.params.length !== 1) {\n return;\n }\n\n each(node.params, function (param) {\n if (param.type !== 'StringLiteral') {\n return;\n }\n\n true && !false && (0, _emberDebug.deprecate)(deprecationMessage(moduleName, node), false, {\n id: 'ember-template-compiler.deprecate-render',\n until: '3.0.0',\n url: 'https://emberjs.com/deprecations/v2.x#toc_code-render-code-helper'\n });\n });\n }\n }\n };\n };\n\n\n function each(list, callback) {\n var i, l;\n\n for (i = 0, l = list.length; i < l; i++) {\n callback(list[i]);\n }\n }\n\n function deprecationMessage(moduleName, node) {\n var sourceInformation = (0, _calculateLocationDisplay.default)(moduleName, node.loc);\n var componentName = node.params[0].original;\n\n\n return 'Please refactor `' + ('{{render \"' + componentName + '\"}}') + '` to a component and invoke via' + (' `' + ('{{' + componentName + '}}') + '`. ' + sourceInformation);\n }\n});","enifed('ember-template-compiler/plugins/extract-pragma-tag', ['exports'], function (exports) {\n 'use strict';\n\n exports.default = function (env) {\n var meta = env.meta;\n\n return {\n name: 'exract-pragma-tag',\n\n visitors: {\n MustacheStatement: {\n enter: function (node) {\n if (node.path.type === 'PathExpression' && node.path.original === PRAGMA_TAG) {\n meta.managerId = node.params[0].value;\n return null;\n }\n }\n }\n }\n };\n };\n var PRAGMA_TAG = 'use-component-manager';\n});","enifed('ember-template-compiler/plugins/index', ['exports', 'ember-template-compiler/plugins/transform-old-binding-syntax', 'ember-template-compiler/plugins/transform-angle-bracket-components', 'ember-template-compiler/plugins/transform-input-on-to-onEvent', 'ember-template-compiler/plugins/transform-top-level-components', 'ember-template-compiler/plugins/transform-inline-link-to', 'ember-template-compiler/plugins/transform-old-class-binding-syntax', 'ember-template-compiler/plugins/transform-quoted-bindings-into-just-bindings', 'ember-template-compiler/plugins/deprecate-render-model', 'ember-template-compiler/plugins/deprecate-render', 'ember-template-compiler/plugins/assert-reserved-named-arguments', 'ember-template-compiler/plugins/transform-action-syntax', 'ember-template-compiler/plugins/transform-input-type-syntax', 'ember-template-compiler/plugins/transform-attrs-into-args', 'ember-template-compiler/plugins/transform-each-in-into-each', 'ember-template-compiler/plugins/transform-has-block-syntax', 'ember-template-compiler/plugins/transform-dot-component-invocation', 'ember-template-compiler/plugins/extract-pragma-tag', 'ember-template-compiler/plugins/assert-input-helper-without-block', 'ember/features'], function (exports, _transformOldBindingSyntax, _transformAngleBracketComponents, _transformInputOnToOnEvent, _transformTopLevelComponents, _transformInlineLinkTo, _transformOldClassBindingSyntax, _transformQuotedBindingsIntoJustBindings, _deprecateRenderModel, _deprecateRender, _assertReservedNamedArguments, _transformActionSyntax, _transformInputTypeSyntax, _transformAttrsIntoArgs, _transformEachInIntoEach, _transformHasBlockSyntax, _transformDotComponentInvocation, _extractPragmaTag, _assertInputHelperWithoutBlock, _features) {\n 'use strict';\n\n var transforms = [_transformDotComponentInvocation.default, _transformOldBindingSyntax.default, _transformAngleBracketComponents.default, _transformInputOnToOnEvent.default, _transformTopLevelComponents.default, _transformInlineLinkTo.default, _transformOldClassBindingSyntax.default, _transformQuotedBindingsIntoJustBindings.default, _deprecateRenderModel.default, _deprecateRender.default, _assertReservedNamedArguments.default, _transformActionSyntax.default, _transformInputTypeSyntax.default, _transformAttrsIntoArgs.default, _transformEachInIntoEach.default, _transformHasBlockSyntax.default, _assertInputHelperWithoutBlock.default];\n\n if (_features.GLIMMER_CUSTOM_COMPONENT_MANAGER) {\n transforms.push(_extractPragmaTag.default);\n }\n\n exports.default = Object.freeze(transforms);\n});","enifed('ember-template-compiler/plugins/transform-action-syntax', ['exports'], function (exports) {\n 'use strict';\n\n exports.default =\n /**\n @module ember\n */\n\n /**\n A Glimmer2 AST transformation that replaces all instances of\n \n ```handlebars\n