diff --git a/accessible/README.md b/accessible/README.md
deleted file mode 100644
index a69fa6667..000000000
--- a/accessible/README.md
+++ /dev/null
@@ -1,54 +0,0 @@
-Accessible Blockly
-==================
-
-Google's Blockly is a web-based, visual programming editor that is accessible
-to blind users.
-
-The code in this directory renders a version of the Blockly toolbox and
-workspace that is fully keyboard-navigable, and compatible with most screen
-readers. It is optimized for NVDA on Firefox.
-
-In the future, Accessible Blockly may be modified to suit accessibility needs
-other than visual impairments. Note that deaf users are expected to continue
-using Blockly over Accessible Blockly.
-
-
-Using Accessible Blockly in Your Web App
-----------------------------------------
-The demo at blockly/demos/accessible covers the absolute minimum required to
-import Accessible Blockly into your web app. You will need to import the files
-in the same order as in the demo: utils.service.js will need to be the first
-Angular file imported.
-
-When the DOMContentLoaded event fires, call ng.platform.browser.bootstrap() on
-the main component to be loaded. This will usually be blocklyApp.AppComponent,
-but if you have another component that wraps it, use that one instead.
-
-
-Customizing the Sidebar and Audio
----------------------------------
-The Accessible Blockly workspace comes with a customizable sidebar.
-
-To customize the sidebar, you will need to declare an ACCESSIBLE_GLOBALS object
-in the global scope that looks like this:
-
- var ACCESSIBLE_GLOBALS = {
- mediaPathPrefix: null,
- customSidebarButtons: []
- };
-
-The value of mediaPathPrefix should be the location of the accessible/media
-folder.
-
-The value of 'customSidebarButtons' should be a list of objects, each
-representing buttons on the sidebar. Each of these objects should have the
-following keys:
- - 'text' (the text to display on the button)
- - 'action' (the function that gets run when the button is clicked)
- - 'id' (optional; the id of the button)
-
-
-Limitations
------------
-- We do not support having multiple Accessible Blockly apps in a single webpage.
-- Accessible Blockly does not support the use of shadow blocks.
diff --git a/accessible/app.component.js b/accessible/app.component.js
deleted file mode 100644
index c31fd4259..000000000
--- a/accessible/app.component.js
+++ /dev/null
@@ -1,109 +0,0 @@
-/**
- * AccessibleBlockly
- *
- * Copyright 2016 Google Inc.
- * https://developers.google.com/blockly/
- *
- * Licensed under the Apache License, Version 2.0 (the 'License');
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an 'AS IS' BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Top-level component for the Accessible Blockly application.
- * @author madeeha@google.com (Madeeha Ghori)
- */
-
-goog.provide('blocklyApp.AppComponent');
-
-goog.require('Blockly');
-
-goog.require('blocklyApp.AudioService');
-goog.require('blocklyApp.BlockConnectionService');
-goog.require('blocklyApp.BlockOptionsModalComponent');
-goog.require('blocklyApp.BlockOptionsModalService');
-goog.require('blocklyApp.KeyboardInputService');
-goog.require('blocklyApp.NotificationsService');
-goog.require('blocklyApp.SidebarComponent');
-goog.require('blocklyApp.ToolboxModalComponent');
-goog.require('blocklyApp.ToolboxModalService');
-goog.require('blocklyApp.TranslatePipe');
-goog.require('blocklyApp.TreeService');
-goog.require('blocklyApp.UtilsService');
-goog.require('blocklyApp.VariableAddModalComponent');
-goog.require('blocklyApp.VariableModalService');
-goog.require('blocklyApp.VariableRenameModalComponent');
-goog.require('blocklyApp.VariableRemoveModalComponent');
-goog.require('blocklyApp.WorkspaceComponent');
-
-
-blocklyApp.workspace = new Blockly.Workspace();
-
-blocklyApp.AppComponent = ng.core.Component({
- selector: 'blockly-app',
- template: `
-
-
-
-
- {{getAriaLiveReadout()}}
-
-
-
-
-
-
-
-
-
-
- `,
- directives: [
- blocklyApp.BlockOptionsModalComponent,
- blocklyApp.SidebarComponent,
- blocklyApp.ToolboxModalComponent,
- blocklyApp.VariableAddModalComponent,
- blocklyApp.VariableRenameModalComponent,
- blocklyApp.VariableRemoveModalComponent,
- blocklyApp.WorkspaceComponent
- ],
- pipes: [blocklyApp.TranslatePipe],
- // All services are declared here, so that all components in the application
- // use the same instance of the service.
- // https://www.sitepoint.com/angular-2-components-providers-classes-factories-values/
- providers: [
- blocklyApp.AudioService,
- blocklyApp.BlockConnectionService,
- blocklyApp.BlockOptionsModalService,
- blocklyApp.KeyboardInputService,
- blocklyApp.NotificationsService,
- blocklyApp.ToolboxModalService,
- blocklyApp.TreeService,
- blocklyApp.UtilsService,
- blocklyApp.VariableModalService
- ]
-})
-.Class({
- constructor: [
- blocklyApp.NotificationsService, function(notificationsService) {
- this.notificationsService = notificationsService;
- }
- ],
- getAriaLiveReadout: function() {
- return this.notificationsService.getDisplayedMessage();
- }
-});
diff --git a/accessible/audio.service.js b/accessible/audio.service.js
deleted file mode 100644
index 4f7eb4f08..000000000
--- a/accessible/audio.service.js
+++ /dev/null
@@ -1,96 +0,0 @@
-/**
- * AccessibleBlockly
- *
- * Copyright 2016 Google Inc.
- * https://developers.google.com/blockly/
- *
- * Licensed under the Apache License, Version 2.0 (the 'License');
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an 'AS IS' BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Angular2 Service for playing audio files.
- * @author sll@google.com (Sean Lip)
- */
-
-goog.provide('blocklyApp.AudioService');
-
-goog.require('blocklyApp.NotificationsService');
-
-
-blocklyApp.AudioService = ng.core.Class({
- constructor: [
- blocklyApp.NotificationsService, function(notificationsService) {
- this.notificationsService = notificationsService;
-
- // We do not play any audio unless a media path prefix is specified.
- this.canPlayAudio = false;
-
- if (ACCESSIBLE_GLOBALS.hasOwnProperty('mediaPathPrefix')) {
- this.canPlayAudio = true;
- var mediaPathPrefix = ACCESSIBLE_GLOBALS['mediaPathPrefix'];
- this.AUDIO_PATHS_ = {
- 'connect': mediaPathPrefix + 'click.mp3',
- 'delete': mediaPathPrefix + 'delete.mp3',
- 'oops': mediaPathPrefix + 'oops.mp3'
- };
- }
-
- this.cachedAudioFiles_ = {};
- // Store callback references here so that they can be removed if a new
- // call to this.play_() comes in.
- this.onEndedCallbacks_ = {
- 'connect': [],
- 'delete': [],
- 'oops': []
- };
- }
- ],
- play_: function(audioId, onEndedCallback) {
- if (this.canPlayAudio) {
- if (!this.cachedAudioFiles_.hasOwnProperty(audioId)) {
- this.cachedAudioFiles_[audioId] = new Audio(this.AUDIO_PATHS_[audioId]);
- }
-
- if (onEndedCallback) {
- this.onEndedCallbacks_[audioId].push(onEndedCallback);
- this.cachedAudioFiles_[audioId].addEventListener(
- 'ended', onEndedCallback);
- } else {
- var that = this;
- this.onEndedCallbacks_[audioId].forEach(function(callback) {
- that.cachedAudioFiles_[audioId].removeEventListener(
- 'ended', callback);
- });
- this.onEndedCallbacks_[audioId].length = 0;
- }
-
- this.cachedAudioFiles_[audioId].play();
- }
- },
- playConnectSound: function() {
- this.play_('connect');
- },
- playDeleteSound: function() {
- this.play_('delete');
- },
- playOopsSound: function(optionalStatusMessage) {
- if (optionalStatusMessage) {
- var that = this;
- this.play_('oops', function() {
- that.notificationsService.speak(optionalStatusMessage);
- });
- } else {
- this.play_('oops');
- }
- }
-});
diff --git a/accessible/block-connection.service.js b/accessible/block-connection.service.js
deleted file mode 100644
index d2c5cd866..000000000
--- a/accessible/block-connection.service.js
+++ /dev/null
@@ -1,135 +0,0 @@
-/**
- * AccessibleBlockly
- *
- * Copyright 2016 Google Inc.
- * https://developers.google.com/blockly/
- *
- * Licensed under the Apache License, Version 2.0 (the 'License');
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an 'AS IS' BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Angular2 Service for handling the mechanics of how blocks
- * get connected to each other.
- * @author sll@google.com (Sean Lip)
- */
-
-goog.provide('blocklyApp.BlockConnectionService');
-
-goog.require('blocklyApp.AudioService');
-goog.require('blocklyApp.NotificationsService');
-
-
-blocklyApp.BlockConnectionService = ng.core.Class({
- constructor: [
- blocklyApp.NotificationsService, blocklyApp.AudioService,
- function(_notificationsService, _audioService) {
- this.notificationsService = _notificationsService;
- this.audioService = _audioService;
-
- // When a user "adds a link" to a block, the connection representing this
- // link is stored here.
- this.markedConnection_ = null;
- }],
- findCompatibleConnection_: function(block, targetConnection) {
- // Locates and returns a connection on the given block that is compatible
- // with the target connection, if one exists. Returns null if no such
- // connection exists.
- // Note: the targetConnection is assumed to be the markedConnection_, or
- // possibly its counterpart (in the case where the marked connection is
- // currently attached to another connection). This method therefore ignores
- // input connections on the given block, since one doesn't usually mark an
- // output connection and attach a block to it.
- if (!targetConnection || !targetConnection.getSourceBlock().workspace) {
- return null;
- }
-
- var desiredType = Blockly.OPPOSITE_TYPE[targetConnection.type];
- var potentialConnection = (
- desiredType == Blockly.OUTPUT_VALUE ? block.outputConnection :
- desiredType == Blockly.PREVIOUS_STATEMENT ? block.previousConnection :
- desiredType == Blockly.NEXT_STATEMENT ? block.nextConnection :
- null);
-
- if (potentialConnection &&
- potentialConnection.checkType_(targetConnection)) {
- return potentialConnection;
- } else {
- return null;
- }
- },
- isAnyConnectionMarked: function() {
- return Boolean(this.markedConnection_);
- },
- getMarkedConnectionSourceBlock: function() {
- return this.markedConnection_ ?
- this.markedConnection_.getSourceBlock() : null;
- },
- canBeAttachedToMarkedConnection: function(block) {
- return Boolean(
- this.findCompatibleConnection_(block, this.markedConnection_));
- },
- canBeMovedToMarkedConnection: function(block) {
- if (!this.markedConnection_) {
- return false;
- }
-
- // It should not be possible to move any ancestor of the block containing
- // the marked connection to the marked connection.
- var ancestorBlock = this.getMarkedConnectionSourceBlock();
- while (ancestorBlock) {
- if (ancestorBlock.id == block.id) {
- return false;
- }
- ancestorBlock = ancestorBlock.getParent();
- }
-
- return this.canBeAttachedToMarkedConnection(block);
- },
- markConnection: function(connection) {
- this.markedConnection_ = connection;
- this.notificationsService.speak(Blockly.Msg.ADDED_LINK_MSG);
- },
- attachToMarkedConnection: function(block) {
- var xml = Blockly.Xml.blockToDom(block);
- var reconstitutedBlock = Blockly.Xml.domToBlock(xml, blocklyApp.workspace);
-
- var targetConnection = null;
- if (this.markedConnection_.targetBlock() &&
- this.markedConnection_.type == Blockly.PREVIOUS_STATEMENT) {
- // Is the marked connection a 'previous' connection that is already
- // connected? If so, find the block that's currently connected to it, and
- // use that block's 'next' connection as the new marked connection.
- // Otherwise, splicing does not happen correctly, and inserting a block
- // in the middle of a group of two linked blocks will split the group.
- targetConnection = this.markedConnection_.targetConnection;
- } else {
- targetConnection = this.markedConnection_;
- }
-
- var connection = this.findCompatibleConnection_(
- reconstitutedBlock, targetConnection);
- if (connection) {
- targetConnection.connect(connection);
-
- this.markedConnection_ = null;
- this.audioService.playConnectSound();
- return reconstitutedBlock.id;
- } else {
- // We throw an error here, because we expect any UI controls that would
- // result in a non-connection to be disabled or hidden.
- throw Error(
- 'Unable to connect block to marked connection. This should not ' +
- 'happen.');
- }
- }
-});
diff --git a/accessible/block-options-modal.component.js b/accessible/block-options-modal.component.js
deleted file mode 100644
index 6ac7975b5..000000000
--- a/accessible/block-options-modal.component.js
+++ /dev/null
@@ -1,146 +0,0 @@
-/**
- * AccessibleBlockly
- *
- * Copyright 2016 Google Inc.
- * https://developers.google.com/blockly/
- *
- * Licensed under the Apache License, Version 2.0 (the 'License');
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an 'AS IS' BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Angular2 Component that represents the block options modal.
- *
- * @author sll@google.com (Sean Lip)
- */
-
-goog.provide('blocklyApp.BlockOptionsModalComponent');
-
-goog.require('blocklyApp.AudioService');
-goog.require('blocklyApp.BlockOptionsModalService');
-goog.require('blocklyApp.KeyboardInputService');
-goog.require('blocklyApp.TranslatePipe');
-
-goog.require('Blockly.CommonModal');
-
-
-blocklyApp.BlockOptionsModalComponent = ng.core.Component({
- selector: 'blockly-block-options-modal',
- template: `
-
-
-
-
{{'BLOCK_OPTIONS'|translate}}
-
-
-
-
-
-
-
-
-
-
-
- `,
- pipes: [blocklyApp.TranslatePipe]
-})
-.Class({
- constructor: [
- blocklyApp.BlockOptionsModalService, blocklyApp.KeyboardInputService,
- blocklyApp.AudioService,
- function(blockOptionsModalService_, keyboardInputService_, audioService_) {
- this.blockOptionsModalService = blockOptionsModalService_;
- this.keyboardInputService = keyboardInputService_;
- this.audioService = audioService_;
-
- this.modalIsVisible = false;
- this.actionButtonsInfo = [];
- this.activeButtonIndex = -1;
- this.onDismissCallback = null;
-
- var that = this;
- this.blockOptionsModalService.registerPreShowHook(
- function(newActionButtonsInfo, onDismissCallback) {
- that.modalIsVisible = true;
- that.actionButtonsInfo = newActionButtonsInfo;
- that.activeActionButtonIndex = -1;
- that.onDismissCallback = onDismissCallback;
-
- Blockly.CommonModal.setupKeyboardOverrides(that);
- that.keyboardInputService.addOverride('13', function(evt) {
- evt.preventDefault();
- evt.stopPropagation();
-
- if (that.activeButtonIndex == -1) {
- return;
- }
-
- var button = document.getElementById(
- that.getOptionId(that.activeButtonIndex));
- if (that.activeButtonIndex <
- that.actionButtonsInfo.length) {
- that.actionButtonsInfo[that.activeButtonIndex].action();
- } else {
- that.dismissModal();
- }
-
- that.hideModal();
- });
-
- setTimeout(function() {
- document.getElementById('blockOptionsModal').focus();
- }, 150);
- }
- );
- }
- ],
- focusOnOption: function(index) {
- var button = document.getElementById(this.getOptionId(index));
- button.focus();
- },
- // Counts the number of interactive elements for the modal.
- numInteractiveElements: function() {
- return this.actionButtonsInfo.length + 1;
- },
- // Returns the ID for the corresponding option button.
- getOptionId: function(index) {
- return 'block-options-modal-option-' + index;
- },
- // Returns the ID for the "cancel" option button.
- getCancelOptionId: function() {
- return this.getOptionId(this.actionButtonsInfo.length);
- },
- dismissModal: function() {
- this.onDismissCallback();
- this.hideModal();
- },
- // Closes the modal.
- hideModal: function() {
- this.modalIsVisible = false;
- this.keyboardInputService.clearOverride();
- this.blockOptionsModalService.hideModal();
- }
-});
diff --git a/accessible/block-options-modal.service.js b/accessible/block-options-modal.service.js
deleted file mode 100644
index ad775c6d4..000000000
--- a/accessible/block-options-modal.service.js
+++ /dev/null
@@ -1,62 +0,0 @@
-/**
- * AccessibleBlockly
- *
- * Copyright 2016 Google Inc.
- * https://developers.google.com/blockly/
- *
- * Licensed under the Apache License, Version 2.0 (the 'License');
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an 'AS IS' BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Angular2 Service for the block options modal.
- *
- * @author sll@google.com (Sean Lip)
- */
-
-goog.provide('blocklyApp.BlockOptionsModalService');
-
-
-blocklyApp.BlockOptionsModalService = ng.core.Class({
- constructor: [function() {
- this.actionButtonsInfo = [];
- // The aim of the pre-show hook is to populate the modal component with the
- // information it needs to display the modal (e.g., which action buttons to
- // display).
- this.preShowHook = function() {
- throw Error(
- 'A pre-show hook must be defined for the block options modal ' +
- 'before it can be shown.');
- };
- this.modalIsShown = false;
- this.onDismissCallback = null;
- }],
- registerPreShowHook: function(preShowHook) {
- var that = this;
- this.preShowHook = function() {
- preShowHook(that.actionButtonsInfo, that.onDismissCallback);
- };
- },
- isModalShown: function() {
- return this.modalIsShown;
- },
- showModal: function(actionButtonsInfo, onDismissCallback) {
- this.actionButtonsInfo = actionButtonsInfo;
- this.onDismissCallback = onDismissCallback;
-
- this.preShowHook();
- this.modalIsShown = true;
- },
- hideModal: function() {
- this.modalIsShown = false;
- }
-});
diff --git a/accessible/commonModal.js b/accessible/commonModal.js
deleted file mode 100644
index 57e88b529..000000000
--- a/accessible/commonModal.js
+++ /dev/null
@@ -1,77 +0,0 @@
-goog.provide('Blockly.CommonModal');
-
-
-Blockly.CommonModal = function() {};
-
-Blockly.CommonModal.setupKeyboardOverrides = function(component) {
- component.keyboardInputService.setOverride({
- // Tab key: navigates to the previous or next item in the list.
- '9': function(evt) {
- evt.preventDefault();
- evt.stopPropagation();
-
- if (evt.shiftKey) {
- // Move to the previous item in the list.
- if (component.activeButtonIndex <= 0) {
- component.activeActionButtonIndex = 0;
- component.audioService.playOopsSound();
- } else {
- component.activeButtonIndex--;
- }
- } else {
- // Move to the next item in the list.
- if (component.activeButtonIndex == component.numInteractiveElements(component) - 1) {
- component.audioService.playOopsSound();
- } else {
- component.activeButtonIndex++;
- }
- }
-
- component.focusOnOption(component.activeButtonIndex, component);
- },
- // Escape key: closes the modal.
- '27': function() {
- component.dismissModal();
- },
- // Up key: no-op.
- '38': function(evt) {
- evt.preventDefault();
- },
- // Down key: no-op.
- '40': function(evt) {
- evt.preventDefault();
- }
- });
-}
-
-Blockly.CommonModal.getInteractiveElements = function(component) {
- return Array.prototype.filter.call(
- component.getInteractiveContainer().elements, function(element) {
- if (element.type === 'hidden') {
- return false;
- }
- if (element.disabled) {
- return false;
- }
- if (element.tabIndex < 0) {
- return false;
- }
- return true;
- });
-};
-
-Blockly.CommonModal.numInteractiveElements = function(component) {
- var elements = this.getInteractiveElements(component);
- return elements.length;
-};
-
-Blockly.CommonModal.focusOnOption = function(index, component) {
- var elements = this.getInteractiveElements(component);
- var button = elements[index];
- button.focus();
-};
-
-Blockly.CommonModal.hideModal = function() {
- this.modalIsVisible = false;
- this.keyboardInputService.clearOverride();
-};
\ No newline at end of file
diff --git a/accessible/field-segment.component.js b/accessible/field-segment.component.js
deleted file mode 100644
index c68afb455..000000000
--- a/accessible/field-segment.component.js
+++ /dev/null
@@ -1,206 +0,0 @@
-/**
- * AccessibleBlockly
- *
- * Copyright 2016 Google Inc.
- * https://developers.google.com/blockly/
- *
- * Licensed under the Apache License, Version 2.0 (the 'License');
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an 'AS IS' BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Angular2 Component that renders a "field segment" (a group
- * of non-editable Blockly.Field followed by 0 or 1 editable Blockly.Field)
- * in a block. Also handles any interactions with the field.
- * @author madeeha@google.com (Madeeha Ghori)
- */
-
-goog.provide('blocklyApp.FieldSegmentComponent');
-
-goog.require('blocklyApp.NotificationsService');
-goog.require('blocklyApp.TranslatePipe');
-goog.require('blocklyApp.VariableModalService');
-
-
-blocklyApp.FieldSegmentComponent = ng.core.Component({
- selector: 'blockly-field-segment',
- template: `
-
-
-
-
-
-
- {{getPrefixText()}}
-
-
-
-
- {{getPrefixText()}}
-
-
-
-
- {{getPrefixText()}}
-
-
-
- `,
- inputs: ['prefixFields', 'mainField', 'mainFieldId', 'level'],
- pipes: [blocklyApp.TranslatePipe]
-})
-.Class({
- constructor: [
- blocklyApp.NotificationsService,
- blocklyApp.VariableModalService,
- function(notificationsService, variableModalService) {
- this.notificationsService = notificationsService;
- this.variableModalService = variableModalService;
- this.dropdownOptions = [];
- this.rawOptions = [];
- }],
- // Angular2 hook - called after initialization.
- ngAfterContentInit: function() {
- if (this.mainField) {
- this.mainField.initModel();
- }
- },
- // Angular2 hook - called to check if the cached component needs an update.
- ngDoCheck: function() {
- if (this.isDropdown() && this.shouldBreakCache()) {
- this.optionValue = this.mainField.getValue();
- this.fieldValue = this.mainField.getValue();
- this.rawOptions = this.mainField.getOptions();
- this.dropdownOptions = this.rawOptions.map(function(valueAndText) {
- return {
- text: valueAndText[0],
- value: valueAndText[1]
- };
- });
-
- // Set the currently selected value to the variable on the field.
- for (var i = 0; i < this.dropdownOptions.length; i++) {
- if (this.dropdownOptions[i].text === this.fieldValue) {
- this.selectedOption = this.dropdownOptions[i].value;
- }
- }
- }
- },
- // Returns whether the mutable, cached information needs to be refreshed.
- shouldBreakCache: function() {
- var newOptions = this.mainField.getOptions();
- if (newOptions.length != this.rawOptions.length) {
- return true;
- }
-
- for (var i = 0; i < this.rawOptions.length; i++) {
- // Compare the value of the cached options with the values in the field.
- if (newOptions[i][0] != this.rawOptions[i][0]) {
- return true;
- }
- }
-
- if (this.fieldValue != this.mainField.getValue()) {
- return true;
- }
-
- return false;
- },
- // Gets the prefix text, to be printed before a field.
- getPrefixText: function() {
- var prefixTexts = this.prefixFields.map(function(prefixField) {
- return prefixField.getText();
- });
- return prefixTexts.join(' ');
- },
- // Gets the description, for labeling a field.
- getFieldDescription: function() {
- var description = this.mainField.getText();
- if (this.prefixFields.length > 0) {
- description = this.getPrefixText() + ': ' + description;
- }
- return description;
- },
- // Returns true if the field is text input, false otherwise.
- isTextInput: function() {
- return this.mainField instanceof Blockly.FieldTextInput &&
- !(this.mainField instanceof Blockly.FieldNumber);
- },
- // Returns true if the field is number input, false otherwise.
- isNumberInput: function() {
- return this.mainField instanceof Blockly.FieldNumber;
- },
- // Returns true if the field is a dropdown, false otherwise.
- isDropdown: function() {
- return this.mainField instanceof Blockly.FieldDropdown;
- },
- // Sets the text value on the underlying field.
- setTextValue: function(newValue) {
- this.mainField.setValue(newValue);
- },
- // Sets the number value on the underlying field.
- setNumberValue: function(newValue) {
- // Do not permit a residual value of NaN after a backspace event.
- this.mainField.setValue(newValue || 0);
- },
- // Confirm a selection for dropdown fields.
- selectOption: function() {
- if (this.optionValue != Blockly.RENAME_VARIABLE_ID && this.optionValue !=
- Blockly.DELETE_VARIABLE_ID) {
- this.mainField.setValue(this.optionValue);
- }
-
- if (this.optionValue == Blockly.RENAME_VARIABLE_ID) {
- this.variableModalService.showRenameModal_(this.mainField.getValue());
- }
-
- if (this.optionValue == Blockly.DELETE_VARIABLE_ID) {
- this.variableModalService.showRemoveModal_(this.mainField.getValue());
- }
- },
- // Sets the value on a dropdown input.
- setDropdownValue: function(optionValue) {
- this.optionValue = optionValue;
- if (this.optionValue == 'NO_ACTION') {
- return;
- }
-
- var optionText = undefined;
- for (var i = 0; i < this.dropdownOptions.length; i++) {
- if (this.dropdownOptions[i].value == optionValue) {
- optionText = this.dropdownOptions[i].text;
- break;
- }
- }
-
- if (!optionText) {
- throw Error(
- 'There is no option text corresponding to the value: ' +
- this.optionValue);
- }
-
- this.notificationsService.speak('Selected option ' + optionText);
- }
-});
diff --git a/accessible/keyboard-input.service.js b/accessible/keyboard-input.service.js
deleted file mode 100644
index 638275637..000000000
--- a/accessible/keyboard-input.service.js
+++ /dev/null
@@ -1,58 +0,0 @@
-/**
- * AccessibleBlockly
- *
- * Copyright 2016 Google Inc.
- * https://developers.google.com/blockly/
- *
- * Licensed under the Apache License, Version 2.0 (the 'License');
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an 'AS IS' BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Angular2 Service for handling keyboard input.
- *
- * @author sll@google.com (Sean Lip)
- */
-
-goog.provide('blocklyApp.KeyboardInputService');
-
-
-blocklyApp.KeyboardInputService = ng.core.Class({
- constructor: [function() {
- // Default custom actions for global keystrokes. The keys of this object
- // are string representations of the key codes.
- this.keysToActions = {};
- // Override for the default keysToActions mapping (e.g. in a modal
- // context).
- this.keysToActionsOverride = null;
-
- // Attach a keydown handler to the entire window.
- var that = this;
- document.addEventListener('keydown', function(evt) {
- var stringifiedKeycode = String(evt.keyCode);
- var actionsObject = that.keysToActionsOverride || that.keysToActions;
-
- if (actionsObject.hasOwnProperty(stringifiedKeycode)) {
- actionsObject[stringifiedKeycode](evt);
- }
- });
- }],
- setOverride: function(newKeysToActions) {
- this.keysToActionsOverride = newKeysToActions;
- },
- addOverride: function(keyCode, action) {
- this.keysToActionsOverride[keyCode] = action;
- },
- clearOverride: function() {
- this.keysToActionsOverride = null;
- }
-});
diff --git a/accessible/libs/README b/accessible/libs/README
deleted file mode 100644
index ebf4d96ba..000000000
--- a/accessible/libs/README
+++ /dev/null
@@ -1,15 +0,0 @@
-This folder contains the following dependencies for accessible Blockly:
-
-* Angular2 (angular2-all.umd.min.js, angular2-polyfills.min.js)
-* RxJava (Rx.umd.min)
-
-Used for data binding between the core Blockly workspace and accessible Blockly.
-RxJava is required by Angular2.
-Fetched from https://code.angularjs.org/
-The current version is 2.0.0-beta.16.
-
-* ES6 Shim
-
-Required by Angular2, for Javascript files.
-Fetched from https://github.com/paulmillr/es6-shim
-The current version is 0.35.1.
diff --git a/accessible/libs/Rx.umd.min.js b/accessible/libs/Rx.umd.min.js
deleted file mode 100644
index 38c0666b4..000000000
--- a/accessible/libs/Rx.umd.min.js
+++ /dev/null
@@ -1,748 +0,0 @@
-/**
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright 2015-2016 Netflix, Inc.
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
-**/
-/**
- @license
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright 2015-2016 Netflix, Inc.
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
- **/
-(function(w){"object"===typeof exports&&"undefined"!==typeof module?module.exports=w():"function"===typeof define&&define.amd?define([],w):("undefined"!==typeof window?window:"undefined"!==typeof global?global:"undefined"!==typeof self?self:this).Rx=w()})(function(){return function a(b,f,g){function k(e,d){if(!f[e]){if(!b[e]){var c="function"==typeof require&&require;if(!d&&c)return c(e,!0);if(l)return l(e,!0);c=Error("Cannot find module '"+e+"'");throw c.code="MODULE_NOT_FOUND",c;}c=f[e]={exports:{}};
-b[e][0].call(c.exports,function(a){var c=b[e][1][a];return k(c?c:a)},c,c.exports,a,b,f,g)}return f[e].exports}for(var l="function"==typeof require&&require,h=0;h=n?h.complete():(c=b?b(c[e],e):c[e],h.next(c),a.index=e+1,this.schedule(a)))};e.prototype._subscribe=function(a){var c=this.arrayLike,m=this.mapFn,
-n=this.scheduler,b=c.length;if(n)return n.schedule(e.dispatch,0,{arrayLike:c,index:0,length:b,mapFn:m,subscriber:a});for(n=0;n=a.count?b.complete():(b.next(d[e]),b.isUnsubscribed||(a.index=e+1,this.schedule(a)))};d.prototype._subscribe=function(a){var e=this.array,n=e.length,b=this.scheduler;if(b)return b.schedule(d.dispatch,0,{array:e,index:0,count:n,subscriber:a});for(b=0;bd)this.period=0;c&&"function"===typeof c.schedule||(this.scheduler=l.asap)}g(e,a);e.create=function(a,c){void 0===a&&(a=0);void 0===c&&(c=l.asap);return new e(a,c)};e.dispatch=function(a){var c=a.subscriber,e=a.period;c.next(a.index);c.isUnsubscribed||(a.index+=1,this.schedule(a,e))};e.prototype._subscribe=function(a){var c=this.period;a.add(this.scheduler.schedule(e.dispatch,c,{index:0,subscriber:a,period:c}))};return e}(b.Observable);f.IntervalObservable=a},{"../Observable":3,"../scheduler/asap":224,
-"../util/isNumeric":243}],128:[function(a,b,f){var g=this&&this.__extends||function(a,c){function d(){this.constructor=a}for(var e in c)c.hasOwnProperty(e)&&(a[e]=c[e]);a.prototype=null===c?Object.create(c):(d.prototype=c.prototype,new d)},k=a("../util/root"),l=a("../util/isObject"),h=a("../util/tryCatch");b=a("../Observable");var e=a("../util/isFunction"),d=a("../util/SymbolShim"),c=a("../util/errorObject");a=function(a){function b(c,h,f,q){a.call(this);if(null==c)throw Error("iterator cannot be null.");
-if(l.isObject(h))this.thisArg=h,this.scheduler=f;else if(e.isFunction(h))this.project=h,this.thisArg=f,this.scheduler=q;else if(null!=h)throw Error("When provided, `project` must be a function.");if((h=c[d.SymbolShim.iterator])||"string"!==typeof c)if(h||void 0===c.length){if(!h)throw new TypeError("Object is not iterable");c=c[d.SymbolShim.iterator]()}else c=new n(c);else c=new m(c);this.iterator=c}g(b,a);b.create=function(a,c,d,e){return new b(a,c,d,e)};b.dispatch=function(a){var d=a.index,e=a.thisArg,
-m=a.project,b=a.iterator,n=a.subscriber;a.hasError?n.error(a.error):(b=b.next(),b.done?n.complete():(m?(b=h.tryCatch(m).call(e,b.value,d),b===c.errorObject?(a.error=c.errorObject.e,a.hasError=!0):(n.next(b),a.index=d+1)):(n.next(b.value),a.index=d+1),n.isUnsubscribed||this.schedule(a)))};b.prototype._subscribe=function(a){var d=0,e=this.iterator,m=this.project,n=this.thisArg,f=this.scheduler;if(f)return f.schedule(b.dispatch,0,{index:d,thisArg:n,project:m,iterator:e,subscriber:a});do{f=e.next();if(f.done){a.complete();
-break}else if(m){f=h.tryCatch(m).call(n,f.value,d++);if(f===c.errorObject){a.error(c.errorObject.e);break}a.next(f)}else a.next(f.value);if(a.isUnsubscribed)break}while(1)};return b}(b.Observable);f.IteratorObservable=a;var m=function(){function a(c,d,e){void 0===d&&(d=0);void 0===e&&(e=c.length);this.str=c;this.idx=d;this.len=e}a.prototype[d.SymbolShim.iterator]=function(){return this};a.prototype.next=function(){return this.idxm?-1:1;e=m*Math.floor(Math.abs(e));e=0>=e?0:e>q?q:e}this.arr=c;this.idx=d;this.len=e}a.prototype[d.SymbolShim.iterator]=function(){return this};a.prototype.next=function(){return this.idx=a.end?c.complete():(c.next(e),c.isUnsubscribed||(a.index=d+1,a.start=e+1,this.schedule(a)))};b.prototype._subscribe=function(a){var e=0,d=this.start,c=this.end,m=this.scheduler;if(m)return m.schedule(b.dispatch,
-0,{index:e,end:c,start:d,subscriber:a});do{if(e++>=c){a.complete();break}a.next(d++);if(a.isUnsubscribed)break}while(1)};return b}(a("../Observable").Observable);f.RangeObservable=a},{"../Observable":3}],132:[function(a,b,f){var g=this&&this.__extends||function(a,b){function h(){this.constructor=a}for(var e in b)b.hasOwnProperty(e)&&(a[e]=b[e]);a.prototype=null===b?Object.create(b):(h.prototype=b.prototype,new h)};a=function(a){function b(h,e){a.call(this);this.value=h;this.scheduler=e;this._isScalar=
-!0}g(b,a);b.create=function(a,e){return new b(a,e)};b.dispatch=function(a){var e=a.value,d=a.subscriber;a.done?d.complete():(d.next(e),d.isUnsubscribed||(a.done=!0,this.schedule(a)))};b.prototype._subscribe=function(a){var e=this.value,d=this.scheduler;if(d)return d.schedule(b.dispatch,0,{done:!1,value:e,subscriber:a});a.next(e);a.isUnsubscribed||a.complete()};return b}(a("../Observable").Observable);f.ScalarObservable=a},{"../Observable":3}],133:[function(a,b,f){var g=this&&this.__extends||function(a,
-e){function d(){this.constructor=a}for(var c in e)e.hasOwnProperty(c)&&(a[c]=e[c]);a.prototype=null===e?Object.create(e):(d.prototype=e.prototype,new d)};b=a("../Observable");var k=a("../scheduler/asap"),l=a("../util/isNumeric");a=function(a){function e(d,c,e){void 0===c&&(c=0);void 0===e&&(e=k.asap);a.call(this);this.source=d;this.delayTime=c;this.scheduler=e;if(!l.isNumeric(c)||0>c)this.delayTime=0;e&&"function"===typeof e.schedule||(this.scheduler=k.asap)}g(e,a);e.create=function(a,c,m){void 0===
-c&&(c=0);void 0===m&&(m=k.asap);return new e(a,c,m)};e.dispatch=function(a){return a.source.subscribe(a.subscriber)};e.prototype._subscribe=function(a){return this.scheduler.schedule(e.dispatch,this.delayTime,{source:this.source,subscriber:a})};return e}(b.Observable);f.SubscribeOnObservable=a},{"../Observable":3,"../scheduler/asap":224,"../util/isNumeric":243}],134:[function(a,b,f){var g=this&&this.__extends||function(a,c){function e(){this.constructor=a}for(var b in c)c.hasOwnProperty(b)&&(a[b]=
-c[b]);a.prototype=null===c?Object.create(c):(e.prototype=c.prototype,new e)},k=a("../util/isNumeric");b=a("../Observable");var l=a("../scheduler/asap"),h=a("../util/isScheduler"),e=a("../util/isDate");a=function(a){function c(c,b,f){void 0===c&&(c=0);a.call(this);this.period=-1;this.dueTime=0;k.isNumeric(b)?this.period=1>+b&&1||+b:h.isScheduler(b)&&(f=b);h.isScheduler(f)||(f=l.asap);this.scheduler=f;this.dueTime=e.isDate(c)?+c-this.scheduler.now():c}g(c,a);c.create=function(a,d,e){void 0===a&&(a=
-0);return new c(a,d,e)};c.dispatch=function(a){var c=a.index,d=a.period,e=a.subscriber;e.next(c);if(!e.isUnsubscribed){if(-1===d)return e.complete();a.index=c+1;this.schedule(a,d)}};c.prototype._subscribe=function(a){return this.scheduler.schedule(c.dispatch,this.dueTime,{index:0,period:this.period,subscriber:a})};return c}(b.Observable);f.TimerObservable=a},{"../Observable":3,"../scheduler/asap":224,"../util/isDate":241,"../util/isNumeric":243,"../util/isScheduler":246}],135:[function(a,b,f){var g=
-this&&this.__extends||function(a,d){function c(){this.constructor=a}for(var b in d)d.hasOwnProperty(b)&&(a[b]=d[b]);a.prototype=null===d?Object.create(d):(c.prototype=d.prototype,new c)};b=a("../OuterSubscriber");var k=a("../util/subscribeToResult");f.buffer=function(a){return this.lift(new l(a))};var l=function(){function a(d){this.closingNotifier=d}a.prototype.call=function(a){return new h(a,this.closingNotifier)};return a}(),h=function(a){function d(c,d){a.call(this,c);this.buffer=[];this.add(k.subscribeToResult(this,
-d))}g(d,a);d.prototype._next=function(a){this.buffer.push(a)};d.prototype.notifyNext=function(a,d,e,b,h){a=this.buffer;this.buffer=[];this.destination.next(a)};return d}(b.OuterSubscriber)},{"../OuterSubscriber":6,"../util/subscribeToResult":250}],136:[function(a,b,f){var g=this&&this.__extends||function(a,e){function d(){this.constructor=a}for(var c in e)e.hasOwnProperty(c)&&(a[c]=e[c]);a.prototype=null===e?Object.create(e):(d.prototype=e.prototype,new d)};a=a("../Subscriber");f.bufferCount=function(a,
-e){void 0===e&&(e=null);return this.lift(new k(a,e))};var k=function(){function a(e,d){this.bufferSize=e;this.startBufferEvery=d}a.prototype.call=function(a){return new l(a,this.bufferSize,this.startBufferEvery)};return a}(),l=function(a){function e(d,c,e){a.call(this,d);this.bufferSize=c;this.startBufferEvery=e;this.buffers=[[]];this.count=0}g(e,a);e.prototype._next=function(a){var c=this.count+=1,e=this.destination,b=this.bufferSize,h=this.buffers,f=h.length,k=-1;0===c%(null==this.startBufferEvery?
-b:this.startBufferEvery)&&h.push([]);for(c=0;c=d[0].time-e.now();)d.shift().notification.observe(b);0(d||0)?Number.POSITIVE_INFINITY:d;return this.lift(new e(a,d,b))};var e=function(){function a(c,d,e){this.project=c;this.concurrent=d;this.scheduler=e}a.prototype.call=function(a){return new d(a,this.project,this.concurrent,this.scheduler)};return a}();f.ExpandOperator=e;var d=function(a){function d(e,b,m,h){a.call(this,
-e);this.project=b;this.concurrent=m;this.scheduler=h;this.active=this.index=0;this.hasCompleted=!1;ma?this.lift(new l(-1,this)):this.lift(new l(a-1,this))};var l=function(){function a(d,c){this.count=d;this.source=c}a.prototype.call=function(a){return new h(a,
-this.count,this.source)};return a}(),h=function(a){function d(c,d,b){a.call(this,c);this.count=d;this.source=b}g(d,a);d.prototype.complete=function(){if(!this.isStopped){var c=this.source,d=this.count;if(0===d)return a.prototype.complete.call(this);-1this.total&&this.destination.next(a)};return b}(a.Subscriber)},{"../Subscriber":9}],194:[function(a,b,f){var g=this&&this.__extends||function(a,d){function c(){this.constructor=a}for(var b in d)d.hasOwnProperty(b)&&(a[b]=d[b]);a.prototype=null===d?Object.create(d):(c.prototype=d.prototype,new c)};b=a("../OuterSubscriber");
-var k=a("../util/subscribeToResult");f.skipUntil=function(a){return this.lift(new l(a))};var l=function(){function a(d){this.notifier=d}a.prototype.call=function(a){return new h(a,this.notifier)};return a}(),h=function(a){function d(c,d){a.call(this,c);this.isInnerStopped=this.hasValue=!1;this.add(k.subscribeToResult(this,d))}g(d,a);d.prototype._next=function(c){this.hasValue&&a.prototype._next.call(this,c)};d.prototype._complete=function(){this.isInnerStopped?a.prototype._complete.call(this):this.unsubscribe()};
-d.prototype.notifyNext=function(a,d,b,e,f){this.hasValue=!0};d.prototype.notifyComplete=function(){this.isInnerStopped=!0;this.isStopped&&a.prototype._complete.call(this)};return d}(b.OuterSubscriber)},{"../OuterSubscriber":6,"../util/subscribeToResult":250}],195:[function(a,b,f){var g=this&&this.__extends||function(a,b){function d(){this.constructor=a}for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);a.prototype=null===b?Object.create(b):(d.prototype=b.prototype,new d)};a=a("../Subscriber");f.skipWhile=
-function(a){return this.lift(new k(a))};var k=function(){function a(b){this.predicate=b}a.prototype.call=function(a){return new l(a,this.predicate)};return a}(),l=function(a){function b(d,c){a.call(this,d);this.predicate=c;this.skipping=!0;this.index=0}g(b,a);b.prototype._next=function(a){var c=this.destination;this.skipping&&this.tryCallPredicate(a);this.skipping||c.next(a)};b.prototype.tryCallPredicate=function(a){try{this.skipping=!!this.predicate(a,this.index++)}catch(c){this.destination.error(c)}};
-return b}(a.Subscriber)},{"../Subscriber":9}],196:[function(a,b,f){var g=a("../observable/ArrayObservable"),k=a("../observable/ScalarObservable"),l=a("../observable/EmptyObservable"),h=a("./concat"),e=a("../util/isScheduler");f.startWith=function(){for(var a=[],c=0;cthis.total)throw new k.ArgumentOutOfRangeError;}a.prototype.call=
-function(a){return new e(a,this.total)};return a}(),e=function(a){function c(c,b){a.call(this,c);this.total=b;this.count=0}g(c,a);c.prototype._next=function(a){var c=this.total;++this.count<=c&&(this.destination.next(a),this.count===c&&this.destination.complete())};return c}(b.Subscriber)},{"../Subscriber":9,"../observable/EmptyObservable":121,"../util/ArgumentOutOfRangeError":231}],202:[function(a,b,f){var g=this&&this.__extends||function(a,c){function b(){this.constructor=a}for(var e in c)c.hasOwnProperty(e)&&
-(a[e]=c[e]);a.prototype=null===c?Object.create(c):(b.prototype=c.prototype,new b)};b=a("../Subscriber");var k=a("../util/ArgumentOutOfRangeError"),l=a("../observable/EmptyObservable");f.takeLast=function(a){return 0===a?new l.EmptyObservable:this.lift(new h(a))};var h=function(){function a(c){this.total=c;if(0>this.total)throw new k.ArgumentOutOfRangeError;}a.prototype.call=function(a){return new e(a,this.total)};return a}(),e=function(a){function c(c,b){a.call(this,c);this.total=b;this.index=this.count=
-0;this.ring=Array(b)}g(c,a);c.prototype._next=function(a){var c=this.index,d=this.ring,b=this.total,e=this.count;1this.index};a.prototype.hasCompleted=function(){return this.array.length===this.index};return a}(),u=function(a){function b(c,d,e,f){a.call(this,c);this.parent=d;this.observable=e;this.index=f;this.stillUnsubscribed=!0;this.buffer=[];this.isComplete=!1}k(b,a);b.prototype[c.SymbolShim.iterator]=function(){return this};b.prototype.next=
-function(){var a=this.buffer;return 0===a.length&&this.isComplete?{done:!0}:{value:a.shift(),done:!1}};b.prototype.hasValue=function(){return 0=b?this.scheduleNow(a,d):this.scheduleLater(a,b,d)};a.prototype.scheduleNow=function(a,b){return(new g.QueueAction(this,a)).schedule(b)};a.prototype.scheduleLater=function(a,b,d){return(new k.FutureAction(this,a)).schedule(d,b)};return a}();
-f.QueueScheduler=a},{"./FutureAction":221,"./QueueAction":222}],224:[function(a,b,f){a=a("./AsapScheduler");f.asap=new a.AsapScheduler},{"./AsapScheduler":220}],225:[function(a,b,f){a=a("./QueueScheduler");f.queue=new a.QueueScheduler},{"./QueueScheduler":223}],226:[function(a,b,f){var g=this&&this.__extends||function(a,b){function f(){this.constructor=a}for(var e in b)b.hasOwnProperty(e)&&(a[e]=b[e]);a.prototype=null===b?Object.create(b):(f.prototype=b.prototype,new f)};a=function(a){function b(){a.apply(this,
-arguments);this.value=null;this.hasNext=!1}g(b,a);b.prototype._subscribe=function(b){this.hasCompleted&&this.hasNext&&b.next(this.value);return a.prototype._subscribe.call(this,b)};b.prototype._next=function(a){this.value=a;this.hasNext=!0};b.prototype._complete=function(){var a=-1,b=this.observers,d=b.length;this.isUnsubscribed=!0;if(this.hasNext)for(;++ac?1:c;
-this._windowTime=1>d?1:d}g(b,a);b.prototype._next=function(b){var d=this._getNow();this.events.push(new h(d,b));this._trimBufferThenGetEvents(d);a.prototype._next.call(this,b)};b.prototype._subscribe=function(b){var d=this._trimBufferThenGetEvents(this._getNow()),f=this.scheduler;f&&b.add(b=new l.ObserveOnSubscriber(b,f));for(var f=-1,g=d.length;++fb&&(g=Math.max(g,f-b));0o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=n(5),a=n(6),u=n(7),c=function(t){function e(e){t.call(this),this.attributeName=e}return r(e,t),Object.defineProperty(e.prototype,"token",{get:function(){return this},enumerable:!0,configurable:!0}),e.prototype.toString=function(){return"@Attribute("+s.stringify(this.attributeName)+")"},e=i([s.CONST(),o("design:paramtypes",[String])],e)}(u.DependencyMetadata);e.AttributeMetadata=c;var p=function(t){function e(e,n){var r=void 0===n?{}:n,i=r.descendants,o=void 0===i?!1:i,s=r.first,a=void 0===s?!1:s,u=r.read,c=void 0===u?null:u;t.call(this),this._selector=e,this.descendants=o,this.first=a,this.read=c}return r(e,t),Object.defineProperty(e.prototype,"isViewQuery",{get:function(){return!1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"selector",{get:function(){return a.resolveForwardRef(this._selector)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isVarBindingQuery",{get:function(){return s.isString(this.selector)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"varBindings",{get:function(){return this.selector.split(",")},enumerable:!0,configurable:!0}),e.prototype.toString=function(){return"@Query("+s.stringify(this.selector)+")"},e=i([s.CONST(),o("design:paramtypes",[Object,Object])],e)}(u.DependencyMetadata);e.QueryMetadata=p;var l=function(t){function e(e,n){var r=void 0===n?{}:n,i=r.descendants,o=void 0===i?!1:i,s=r.read,a=void 0===s?null:s;t.call(this,e,{descendants:o,read:a})}return r(e,t),e=i([s.CONST(),o("design:paramtypes",[Object,Object])],e)}(p);e.ContentChildrenMetadata=l;var h=function(t){function e(e,n){var r=(void 0===n?{}:n).read,i=void 0===r?null:r;t.call(this,e,{descendants:!0,first:!0,read:i})}return r(e,t),e=i([s.CONST(),o("design:paramtypes",[Object,Object])],e)}(p);e.ContentChildMetadata=h;var f=function(t){function e(e,n){var r=void 0===n?{}:n,i=r.descendants,o=void 0===i?!1:i,s=r.first,a=void 0===s?!1:s,u=r.read,c=void 0===u?null:u;t.call(this,e,{descendants:o,first:a,read:c})}return r(e,t),Object.defineProperty(e.prototype,"isViewQuery",{get:function(){return!0},enumerable:!0,configurable:!0}),e.prototype.toString=function(){return"@ViewQuery("+s.stringify(this.selector)+")"},e=i([s.CONST(),o("design:paramtypes",[Object,Object])],e)}(p);e.ViewQueryMetadata=f;var d=function(t){function e(e,n){var r=(void 0===n?{}:n).read,i=void 0===r?null:r;t.call(this,e,{descendants:!0,read:i})}return r(e,t),e=i([s.CONST(),o("design:paramtypes",[Object,Object])],e)}(f);e.ViewChildrenMetadata=d;var v=function(t){function e(e,n){var r=(void 0===n?{}:n).read,i=void 0===r?null:r;t.call(this,e,{descendants:!0,first:!0,read:i})}return r(e,t),e=i([s.CONST(),o("design:paramtypes",[Object,Object])],e)}(f);e.ViewChildMetadata=v},function(t,e){(function(t){"use strict";function n(t){Zone.current.scheduleMicroTask("scheduleMicrotask",t)}function r(t){return t.name?t.name:typeof t}function i(){H=!0}function o(){if(H)throw"Cannot enable prod mode after platform setup.";W=!1}function s(){return W}function a(t){return t}function u(){return function(t){return t}}function c(t){return void 0!==t&&null!==t}function p(t){return void 0===t||null===t}function l(t){return"boolean"==typeof t}function h(t){return"number"==typeof t}function f(t){return"string"==typeof t}function d(t){return"function"==typeof t}function v(t){return d(t)}function y(t){return"object"==typeof t&&null!==t}function m(t){return t instanceof U.Promise}function g(t){return Array.isArray(t)}function _(t){return t instanceof e.Date&&!isNaN(t.valueOf())}function b(){}function P(t){if("string"==typeof t)return t;if(void 0===t||null===t)return""+t;if(t.name)return t.name;if(t.overriddenName)return t.overriddenName;var e=t.toString(),n=e.indexOf("\n");return-1===n?e:e.substring(0,n)}function E(t){return t}function w(t,e){return t}function C(t,e){return t[e]}function R(t,e){return t===e||"number"==typeof t&&"number"==typeof e&&isNaN(t)&&isNaN(e)}function S(t){return t}function O(t){return p(t)?null:t}function T(t){return p(t)?!1:t}function x(t){return null!==t&&("function"==typeof t||"object"==typeof t)}function A(t){console.log(t)}function I(t,e,n){for(var r=e.split("."),i=t;r.length>1;){var o=r.shift();i=i.hasOwnProperty(o)&&c(i[o])?i[o]:i[o]={}}(void 0===i||null===i)&&(i={}),i[r.shift()]=n}function M(){if(p(Y))if(c(Symbol)&&c(Symbol.iterator))Y=Symbol.iterator;else for(var t=Object.getOwnPropertyNames(Map.prototype),e=0;e=0&&t[r]==e;r--)n--;t=t.substring(0,n)}return t},t.replace=function(t,e,n){return t.replace(e,n)},t.replaceAll=function(t,e,n){return t.replace(e,n)},t.slice=function(t,e,n){return void 0===e&&(e=0),void 0===n&&(n=null),t.slice(e,null===n?void 0:n)},t.replaceAllMapped=function(t,e,n){return t.replace(e,function(){for(var t=[],e=0;et?-1:t>e?1:0},t}();e.StringWrapper=X;var q=function(){function t(t){void 0===t&&(t=[]),this.parts=t}return t.prototype.add=function(t){this.parts.push(t)},t.prototype.toString=function(){return this.parts.join("")},t}();e.StringJoiner=q;var G=function(t){function e(e){t.call(this),this.message=e}return F(e,t),e.prototype.toString=function(){return this.message},e}(Error);e.NumberParseError=G;var z=function(){function t(){}return t.toFixed=function(t,e){return t.toFixed(e)},t.equal=function(t,e){return t===e},t.parseIntAutoRadix=function(t){var e=parseInt(t);if(isNaN(e))throw new G("Invalid integer literal when parsing "+t);return e},t.parseInt=function(t,e){if(10==e){if(/^(\-|\+)?[0-9]+$/.test(t))return parseInt(t,e)}else if(16==e){if(/^(\-|\+)?[0-9ABCDEFabcdef]+$/.test(t))return parseInt(t,e)}else{var n=parseInt(t,e);if(!isNaN(n))return n}throw new G("Invalid integer literal when parsing "+t+" in base "+e)},t.parseFloat=function(t){return parseFloat(t)},Object.defineProperty(t,"NaN",{get:function(){return NaN},enumerable:!0,configurable:!0}),t.isNaN=function(t){return isNaN(t)},t.isInteger=function(t){return Number.isInteger(t)},t}();e.NumberWrapper=z,e.RegExp=U.RegExp;var K=function(){function t(){}return t.create=function(t,e){return void 0===e&&(e=""),e=e.replace(/g/g,""),new U.RegExp(t,e+"g")},t.firstMatch=function(t,e){return t.lastIndex=0,t.exec(e)},t.test=function(t,e){return t.lastIndex=0,t.test(e)},t.matcher=function(t,e){return t.lastIndex=0,{re:t,input:e}},t.replaceAll=function(t,e,n){var r=t.exec(e),i="";t.lastIndex=0;for(var o=0;r;)i+=e.substring(o,r.index),i+=n(r),o=r.index+r[0].length,t.lastIndex=o,r=t.exec(e);return i+=e.substring(o)},t}();e.RegExpWrapper=K;var $=function(){function t(){}return t.next=function(t){return t.re.exec(t.input)},t}();e.RegExpMatcherWrapper=$;var Q=function(){function t(){}return t.apply=function(t,e){return t.apply(null,e)},t}();e.FunctionWrapper=Q,e.looseIdentical=R,e.getMapKey=S,e.normalizeBlank=O,e.normalizeBool=T,e.isJsObject=x,e.print=A;var J=function(){function t(){}return t.parse=function(t){return U.JSON.parse(t)},t.stringify=function(t){return U.JSON.stringify(t,null,2)},t}();e.Json=J;var Z=function(){function t(){}return t.create=function(t,n,r,i,o,s,a){return void 0===n&&(n=1),void 0===r&&(r=1),void 0===i&&(i=0),void 0===o&&(o=0),void 0===s&&(s=0),void 0===a&&(a=0),new e.Date(t,n-1,r,i,o,s,a)},t.fromISOString=function(t){return new e.Date(t)},t.fromMillis=function(t){return new e.Date(t)},t.toMillis=function(t){return t.getTime()},t.now=function(){return new e.Date},t.toJson=function(t){return t.toJSON()},t}();e.DateWrapper=Z,e.setValueOnPath=I;var Y=null;e.getSymbolIterator=M,e.evalExpression=k,e.isPrimitive=N,e.hasConstructor=D,e.bitWiseOr=V,e.bitWiseAnd=j,e.escape=L}).call(e,function(){return this}())},function(t,e,n){"use strict";function r(t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n])}var i=n(7);e.InjectMetadata=i.InjectMetadata,e.OptionalMetadata=i.OptionalMetadata,e.InjectableMetadata=i.InjectableMetadata,e.SelfMetadata=i.SelfMetadata,e.HostMetadata=i.HostMetadata,e.SkipSelfMetadata=i.SkipSelfMetadata,e.DependencyMetadata=i.DependencyMetadata,r(n(8));var o=n(10);e.forwardRef=o.forwardRef,e.resolveForwardRef=o.resolveForwardRef;var s=n(11);e.Injector=s.Injector;var a=n(16);e.ReflectiveInjector=a.ReflectiveInjector;var u=n(24);e.Binding=u.Binding,e.ProviderBuilder=u.ProviderBuilder,e.bind=u.bind,e.Provider=u.Provider,e.provide=u.provide;var c=n(17);e.ResolvedReflectiveFactory=c.ResolvedReflectiveFactory,e.ReflectiveDependency=c.ReflectiveDependency;var p=n(22);e.ReflectiveKey=p.ReflectiveKey;var l=n(23);e.NoProviderError=l.NoProviderError,e.AbstractProviderError=l.AbstractProviderError,e.CyclicDependencyError=l.CyclicDependencyError,e.InstantiationError=l.InstantiationError,e.InvalidProviderError=l.InvalidProviderError,e.NoAnnotationError=l.NoAnnotationError,e.OutOfBoundsError=l.OutOfBoundsError;var h=n(25);e.OpaqueToken=h.OpaqueToken},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=function(){function t(t){this.token=t}return t.prototype.toString=function(){return"@Inject("+o.stringify(this.token)+")"},t=r([o.CONST(),i("design:paramtypes",[Object])],t)}();e.InjectMetadata=s;var a=function(){function t(){}return t.prototype.toString=function(){return"@Optional()"},t=r([o.CONST(),i("design:paramtypes",[])],t)}();e.OptionalMetadata=a;var u=function(){function t(){}return Object.defineProperty(t.prototype,"token",{get:function(){return null},enumerable:!0,configurable:!0}),t=r([o.CONST(),i("design:paramtypes",[])],t)}();e.DependencyMetadata=u;var c=function(){function t(){}return t=r([o.CONST(),i("design:paramtypes",[])],t)}();e.InjectableMetadata=c;var p=function(){function t(){}return t.prototype.toString=function(){return"@Self()"},t=r([o.CONST(),i("design:paramtypes",[])],t)}();e.SelfMetadata=p;var l=function(){function t(){}return t.prototype.toString=function(){return"@SkipSelf()"},t=r([o.CONST(),i("design:paramtypes",[])],t)}();e.SkipSelfMetadata=l;var h=function(){function t(){}return t.prototype.toString=function(){return"@Host()"},t=r([o.CONST(),i("design:paramtypes",[])],t)}();e.HostMetadata=h},function(t,e,n){"use strict";var r=n(7),i=n(9);e.Inject=i.makeParamDecorator(r.InjectMetadata),e.Optional=i.makeParamDecorator(r.OptionalMetadata),e.Injectable=i.makeDecorator(r.InjectableMetadata),e.Self=i.makeParamDecorator(r.SelfMetadata),e.Host=i.makeParamDecorator(r.HostMetadata),e.SkipSelf=i.makeParamDecorator(r.SkipSelfMetadata)},function(t,e,n){"use strict";function r(t){return c.isFunction(t)&&t.hasOwnProperty("annotation")&&(t=t.annotation),t}function i(t,e){if(t===Object||t===String||t===Function||t===Number||t===Array)throw new Error("Can not use native "+c.stringify(t)+" as constructor");if(c.isFunction(t))return t;if(t instanceof Array){var n=t,i=t[t.length-1];if(!c.isFunction(i))throw new Error("Last position of Class method array must be Function in key "+e+" was '"+c.stringify(i)+"'");var o=n.length-1;if(o!=i.length)throw new Error("Number of annotations ("+o+") does not match number of arguments ("+i.length+") in the function: "+c.stringify(i));for(var s=[],a=0,u=n.length-1;u>a;a++){var p=[];s.push(p);var h=n[a];if(h instanceof Array)for(var f=0;f-1?(t.splice(n,1),!0):!1},t.clear=function(t){t.length=0},t.isEmpty=function(t){return 0==t.length},t.fill=function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=null),t.fill(e,n,null===r?t.length:r)},t.equals=function(t,e){if(t.length!=e.length)return!1;for(var n=0;nr&&(n=o,r=s)}}return n},t.flatten=function(t){var e=[];return r(t,e),e},t.addAll=function(t,e){for(var n=0;n0&&(this.provider0=e[0],this.keyId0=e[0].key.id),n>1&&(this.provider1=e[1],this.keyId1=e[1].key.id),n>2&&(this.provider2=e[2],this.keyId2=e[2].key.id),n>3&&(this.provider3=e[3],this.keyId3=e[3].key.id),n>4&&(this.provider4=e[4],this.keyId4=e[4].key.id),n>5&&(this.provider5=e[5],this.keyId5=e[5].key.id),n>6&&(this.provider6=e[6],this.keyId6=e[6].key.id),n>7&&(this.provider7=e[7],this.keyId7=e[7].key.id),n>8&&(this.provider8=e[8],this.keyId8=e[8].key.id),n>9&&(this.provider9=e[9],this.keyId9=e[9].key.id)}return t.prototype.getProviderAtIndex=function(t){if(0==t)return this.provider0;if(1==t)return this.provider1;if(2==t)return this.provider2;if(3==t)return this.provider3;if(4==t)return this.provider4;if(5==t)return this.provider5;if(6==t)return this.provider6;if(7==t)return this.provider7;if(8==t)return this.provider8;if(9==t)return this.provider9;throw new s.OutOfBoundsError(t)},t.prototype.createInjectorStrategy=function(t){return new m(t,this)},t}();e.ReflectiveProtoInjectorInlineStrategy=d;var v=function(){function t(t,e){this.providers=e;var n=e.length;this.keyIds=i.ListWrapper.createFixedSize(n);for(var r=0;n>r;r++)this.keyIds[r]=e[r].key.id}return t.prototype.getProviderAtIndex=function(t){if(0>t||t>=this.providers.length)throw new s.OutOfBoundsError(t);return this.providers[t]},t.prototype.createInjectorStrategy=function(t){return new g(this,t)},t}();e.ReflectiveProtoInjectorDynamicStrategy=v;var y=function(){function t(t){this.numberOfProviders=t.length,this._strategy=t.length>h?new v(this,t):new d(this,t)}return t.fromResolvedProviders=function(e){return new t(e)},t.prototype.getProviderAtIndex=function(t){return this._strategy.getProviderAtIndex(t);
-},t}();e.ReflectiveProtoInjector=y;var m=function(){function t(t,e){this.injector=t,this.protoStrategy=e,this.obj0=f,this.obj1=f,this.obj2=f,this.obj3=f,this.obj4=f,this.obj5=f,this.obj6=f,this.obj7=f,this.obj8=f,this.obj9=f}return t.prototype.resetConstructionCounter=function(){this.injector._constructionCounter=0},t.prototype.instantiateProvider=function(t){return this.injector._new(t)},t.prototype.getObjByKeyId=function(t){var e=this.protoStrategy,n=this.injector;return e.keyId0===t?(this.obj0===f&&(this.obj0=n._new(e.provider0)),this.obj0):e.keyId1===t?(this.obj1===f&&(this.obj1=n._new(e.provider1)),this.obj1):e.keyId2===t?(this.obj2===f&&(this.obj2=n._new(e.provider2)),this.obj2):e.keyId3===t?(this.obj3===f&&(this.obj3=n._new(e.provider3)),this.obj3):e.keyId4===t?(this.obj4===f&&(this.obj4=n._new(e.provider4)),this.obj4):e.keyId5===t?(this.obj5===f&&(this.obj5=n._new(e.provider5)),this.obj5):e.keyId6===t?(this.obj6===f&&(this.obj6=n._new(e.provider6)),this.obj6):e.keyId7===t?(this.obj7===f&&(this.obj7=n._new(e.provider7)),this.obj7):e.keyId8===t?(this.obj8===f&&(this.obj8=n._new(e.provider8)),this.obj8):e.keyId9===t?(this.obj9===f&&(this.obj9=n._new(e.provider9)),this.obj9):f},t.prototype.getObjAtIndex=function(t){if(0==t)return this.obj0;if(1==t)return this.obj1;if(2==t)return this.obj2;if(3==t)return this.obj3;if(4==t)return this.obj4;if(5==t)return this.obj5;if(6==t)return this.obj6;if(7==t)return this.obj7;if(8==t)return this.obj8;if(9==t)return this.obj9;throw new s.OutOfBoundsError(t)},t.prototype.getMaxNumberOfObjects=function(){return h},t}();e.ReflectiveInjectorInlineStrategy=m;var g=function(){function t(t,e){this.protoStrategy=t,this.injector=e,this.objs=i.ListWrapper.createFixedSize(t.providers.length),i.ListWrapper.fill(this.objs,f)}return t.prototype.resetConstructionCounter=function(){this.injector._constructionCounter=0},t.prototype.instantiateProvider=function(t){return this.injector._new(t)},t.prototype.getObjByKeyId=function(t){for(var e=this.protoStrategy,n=0;nt||t>=this.objs.length)throw new s.OutOfBoundsError(t);return this.objs[t]},t.prototype.getMaxNumberOfObjects=function(){return this.objs.length},t}();e.ReflectiveInjectorDynamicStrategy=g;var _=function(){function t(){}return t.resolve=function(t){return o.resolveReflectiveProviders(t)},t.resolveAndCreate=function(e,n){void 0===n&&(n=null);var r=t.resolve(e);return t.fromResolvedProviders(r,n)},t.fromResolvedProviders=function(t,e){return void 0===e&&(e=null),new b(y.fromResolvedProviders(t),e)},t.fromResolvedBindings=function(e){return t.fromResolvedProviders(e)},Object.defineProperty(t.prototype,"parent",{get:function(){return u.unimplemented()},enumerable:!0,configurable:!0}),t.prototype.debugContext=function(){return null},t.prototype.resolveAndCreateChild=function(t){return u.unimplemented()},t.prototype.createChildFromResolved=function(t){return u.unimplemented()},t.prototype.resolveAndInstantiate=function(t){return u.unimplemented()},t.prototype.instantiateResolved=function(t){return u.unimplemented()},t}();e.ReflectiveInjector=_;var b=function(){function t(t,e,n){void 0===e&&(e=null),void 0===n&&(n=null),this._debugContext=n,this._constructionCounter=0,this._proto=t,this._parent=e,this._strategy=t._strategy.createInjectorStrategy(this)}return t.prototype.debugContext=function(){return this._debugContext()},t.prototype.get=function(t,e){return void 0===e&&(e=l.THROW_IF_NOT_FOUND),this._getByKey(c.ReflectiveKey.get(t),null,null,e)},t.prototype.getAt=function(t){return this._strategy.getObjAtIndex(t)},Object.defineProperty(t.prototype,"parent",{get:function(){return this._parent},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"internalStrategy",{get:function(){return this._strategy},enumerable:!0,configurable:!0}),t.prototype.resolveAndCreateChild=function(t){var e=_.resolve(t);return this.createChildFromResolved(e)},t.prototype.createChildFromResolved=function(e){var n=new y(e),r=new t(n);return r._parent=this,r},t.prototype.resolveAndInstantiate=function(t){return this.instantiateResolved(_.resolve([t])[0])},t.prototype.instantiateResolved=function(t){return this._instantiateProvider(t)},t.prototype._new=function(t){if(this._constructionCounter++>this._strategy.getMaxNumberOfObjects())throw new s.CyclicDependencyError(this,t.key);return this._instantiateProvider(t)},t.prototype._instantiateProvider=function(t){if(t.multiProvider){for(var e=i.ListWrapper.createFixedSize(t.resolvedFactories.length),n=0;n0?this._getByReflectiveDependency(t,R[0]):null,r=S>1?this._getByReflectiveDependency(t,R[1]):null,i=S>2?this._getByReflectiveDependency(t,R[2]):null,o=S>3?this._getByReflectiveDependency(t,R[3]):null,a=S>4?this._getByReflectiveDependency(t,R[4]):null,c=S>5?this._getByReflectiveDependency(t,R[5]):null,p=S>6?this._getByReflectiveDependency(t,R[6]):null,l=S>7?this._getByReflectiveDependency(t,R[7]):null,h=S>8?this._getByReflectiveDependency(t,R[8]):null,f=S>9?this._getByReflectiveDependency(t,R[9]):null,d=S>10?this._getByReflectiveDependency(t,R[10]):null,v=S>11?this._getByReflectiveDependency(t,R[11]):null,y=S>12?this._getByReflectiveDependency(t,R[12]):null,m=S>13?this._getByReflectiveDependency(t,R[13]):null,g=S>14?this._getByReflectiveDependency(t,R[14]):null,_=S>15?this._getByReflectiveDependency(t,R[15]):null,b=S>16?this._getByReflectiveDependency(t,R[16]):null,P=S>17?this._getByReflectiveDependency(t,R[17]):null,E=S>18?this._getByReflectiveDependency(t,R[18]):null,w=S>19?this._getByReflectiveDependency(t,R[19]):null}catch(O){throw(O instanceof s.AbstractProviderError||O instanceof s.InstantiationError)&&O.addKey(this,t.key),O}var T;try{switch(S){case 0:T=C();break;case 1:T=C(n);break;case 2:T=C(n,r);break;case 3:T=C(n,r,i);break;case 4:T=C(n,r,i,o);break;case 5:T=C(n,r,i,o,a);break;case 6:T=C(n,r,i,o,a,c);break;case 7:T=C(n,r,i,o,a,c,p);break;case 8:T=C(n,r,i,o,a,c,p,l);break;case 9:T=C(n,r,i,o,a,c,p,l,h);break;case 10:T=C(n,r,i,o,a,c,p,l,h,f);break;case 11:T=C(n,r,i,o,a,c,p,l,h,f,d);break;case 12:T=C(n,r,i,o,a,c,p,l,h,f,d,v);break;case 13:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y);break;case 14:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y,m);break;case 15:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y,m,g);break;case 16:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y,m,g,_);break;case 17:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y,m,g,_,b);break;case 18:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y,m,g,_,b,P);break;case 19:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y,m,g,_,b,P,E);break;case 20:T=C(n,r,i,o,a,c,p,l,h,f,d,v,y,m,g,_,b,P,E,w);break;default:throw new u.BaseException("Cannot instantiate '"+t.key.displayName+"' because it has more than 20 dependencies")}}catch(O){throw new s.InstantiationError(this,O,O.stack,t.key)}return T},t.prototype._getByReflectiveDependency=function(t,e){return this._getByKey(e.key,e.lowerBoundVisibility,e.upperBoundVisibility,e.optional?null:l.THROW_IF_NOT_FOUND)},t.prototype._getByKey=function(t,e,n,r){return t===P?this:n instanceof p.SelfMetadata?this._getByKeySelf(t,r):this._getByKeyDefault(t,r,e)},t.prototype._throwOrNull=function(t,e){if(e!==l.THROW_IF_NOT_FOUND)return e;throw new s.NoProviderError(this,t)},t.prototype._getByKeySelf=function(t,e){var n=this._strategy.getObjByKeyId(t.id);return n!==f?n:this._throwOrNull(t,e)},t.prototype._getByKeyDefault=function(e,n,r){var i;for(i=r instanceof p.SkipSelfMetadata?this._parent:this;i instanceof t;){var o=i,s=o._strategy.getObjByKeyId(e.id);if(s!==f)return s;i=o._parent}return null!==i?i.get(e.token,n):this._throwOrNull(e,n)},Object.defineProperty(t.prototype,"displayName",{get:function(){return"ReflectiveInjector(providers: ["+r(this,function(t){return' "'+t.key.displayName+'" '}).join(", ")+"])"},enumerable:!0,configurable:!0}),t.prototype.toString=function(){return this.displayName},t}();e.ReflectiveInjector_=b;var P=c.ReflectiveKey.get(l.Injector)},function(t,e,n){"use strict";function r(t){var e,n;if(h.isPresent(t.useClass)){var r=g.resolveForwardRef(t.useClass);e=d.reflector.factory(r),n=c(r)}else h.isPresent(t.useExisting)?(e=function(t){return t},n=[b.fromKey(v.ReflectiveKey.get(t.useExisting))]):h.isPresent(t.useFactory)?(e=t.useFactory,n=u(t.useFactory,t.dependencies)):(e=function(){return t.useValue},n=P);return new w(e,n)}function i(t){return new E(v.ReflectiveKey.get(t.token),[r(t)],t.multi)}function o(t){var e=a(t,[]),n=e.map(i);return f.MapWrapper.values(s(n,new Map))}function s(t,e){for(var n=0;n1){var e=r(s.ListWrapper.reversed(t)),n=e.map(function(t){return a.stringify(t.token)});return" ("+n.join(" -> ")+")"}return""}var o=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},s=n(15),a=n(5),u=n(12),c=function(t){function e(e,n,r){t.call(this,"DI Exception"),this.keys=[n],this.injectors=[e],this.constructResolvingMessage=r,this.message=this.constructResolvingMessage(this.keys)}return o(e,t),e.prototype.addKey=function(t,e){this.injectors.push(t),this.keys.push(e),this.message=this.constructResolvingMessage(this.keys)},Object.defineProperty(e.prototype,"context",{get:function(){return this.injectors[this.injectors.length-1].debugContext()},enumerable:!0,configurable:!0}),e}(u.BaseException);e.AbstractProviderError=c;var p=function(t){function e(e,n){t.call(this,e,n,function(t){var e=a.stringify(s.ListWrapper.first(t).token);return"No provider for "+e+"!"+i(t)})}return o(e,t),e}(c);e.NoProviderError=p;var l=function(t){function e(e,n){t.call(this,e,n,function(t){return"Cannot instantiate cyclic dependency!"+i(t)})}return o(e,t),e}(c);e.CyclicDependencyError=l;var h=function(t){function e(e,n,r,i){t.call(this,"DI Exception",n,r,null),this.keys=[i],this.injectors=[e]}return o(e,t),e.prototype.addKey=function(t,e){this.injectors.push(t),this.keys.push(e)},Object.defineProperty(e.prototype,"wrapperMessage",{get:function(){var t=a.stringify(s.ListWrapper.first(this.keys).token);return"Error during instantiation of "+t+"!"+i(this.keys)+"."},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"causeKey",{get:function(){return this.keys[0]},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"context",{get:function(){return this.injectors[this.injectors.length-1].debugContext()},enumerable:!0,configurable:!0}),e}(u.WrappedException);e.InstantiationError=h;var f=function(t){function e(e){t.call(this,"Invalid provider - only instances of Provider and Type are allowed, got: "+e.toString())}return o(e,t),e}(u.BaseException);e.InvalidProviderError=f;var d=function(t){function e(n,r){t.call(this,e._genMessage(n,r))}return o(e,t),e._genMessage=function(t,e){for(var n=[],r=0,i=e.length;i>r;r++){var o=e[r];a.isBlank(o)||0==o.length?n.push("?"):n.push(o.map(a.stringify).join(" "))}return"Cannot resolve all parameters for '"+a.stringify(t)+"'("+n.join(", ")+"). Make sure that all the parameters are decorated with Inject or have valid type annotations and that '"+a.stringify(t)+"' is decorated with Injectable."},e}(u.BaseException);e.NoAnnotationError=d;var v=function(t){function e(e){t.call(this,"Index "+e+" is out-of-bounds.")}return o(e,t),e}(u.BaseException);e.OutOfBoundsError=v;var y=function(t){function e(e,n){t.call(this,"Cannot mix multi providers and regular providers, got: "+e.toString()+" "+n.toString())}return o(e,t),e}(u.BaseException);e.MixingMultiProvidersWithRegularProvidersError=y},function(t,e,n){"use strict";function r(t){return new h(t)}function i(t,e){var n=e.useClass,r=e.useValue,i=e.useExisting,o=e.useFactory,s=e.deps,a=e.multi;return new p(t,{useClass:n,useValue:r,useExisting:i,useFactory:o,deps:s,multi:a})}var o=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},s=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},a=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},u=n(5),c=n(12),p=function(){function t(t,e){var n=e.useClass,r=e.useValue,i=e.useExisting,o=e.useFactory,s=e.deps,a=e.multi;this.token=t,this.useClass=n,this.useValue=r,this.useExisting=i,this.useFactory=o,this.dependencies=s,this._multi=a}return Object.defineProperty(t.prototype,"multi",{get:function(){return u.normalizeBool(this._multi)},enumerable:!0,configurable:!0}),t=s([u.CONST(),a("design:paramtypes",[Object,Object])],t)}();e.Provider=p;var l=function(t){function e(e,n){var r=n.toClass,i=n.toValue,o=n.toAlias,s=n.toFactory,a=n.deps,u=n.multi;t.call(this,e,{useClass:r,useValue:i,useExisting:o,useFactory:s,deps:a,multi:u})}return o(e,t),Object.defineProperty(e.prototype,"toClass",{get:function(){return this.useClass},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"toAlias",{get:function(){return this.useExisting},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"toFactory",{get:function(){return this.useFactory},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"toValue",{get:function(){return this.useValue},enumerable:!0,configurable:!0}),e=s([u.CONST(),a("design:paramtypes",[Object,Object])],e)}(p);e.Binding=l,e.bind=r;var h=function(){function t(t){this.token=t}return t.prototype.toClass=function(t){if(!u.isType(t))throw new c.BaseException('Trying to create a class provider but "'+u.stringify(t)+'" is not a class!');return new p(this.token,{useClass:t})},t.prototype.toValue=function(t){return new p(this.token,{useValue:t})},t.prototype.toAlias=function(t){if(u.isBlank(t))throw new c.BaseException("Can not alias "+u.stringify(this.token)+" to a blank value!");return new p(this.token,{useExisting:t})},t.prototype.toFactory=function(t,e){if(!u.isFunction(t))throw new c.BaseException('Trying to create a factory provider but "'+u.stringify(t)+'" is not a function!');return new p(this.token,{useFactory:t,deps:e})},t}();e.ProviderBuilder=h,e.provide=i},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=function(){function t(t){this._desc=t}return t.prototype.toString=function(){return"Token "+this._desc},t=r([o.CONST(),i("design:paramtypes",[String])],t)}();e.OpaqueToken=s},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=n(5),a=n(7),u=n(27),c=function(t){function e(e){var n=void 0===e?{}:e,r=n.selector,i=n.inputs,o=n.outputs,s=n.properties,a=n.events,u=n.host,c=n.bindings,p=n.providers,l=n.exportAs,h=n.queries;t.call(this),this.selector=r,this._inputs=i,this._properties=s,this._outputs=o,this._events=a,this.host=u,this.exportAs=l,this.queries=h,this._providers=p,this._bindings=c}return r(e,t),Object.defineProperty(e.prototype,"inputs",{get:function(){return s.isPresent(this._properties)&&this._properties.length>0?this._properties:this._inputs},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"properties",{get:function(){return this.inputs},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"outputs",{get:function(){return s.isPresent(this._events)&&this._events.length>0?this._events:this._outputs},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"events",{get:function(){return this.outputs},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"providers",{get:function(){return s.isPresent(this._bindings)&&this._bindings.length>0?this._bindings:this._providers},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"bindings",{get:function(){return this.providers},enumerable:!0,configurable:!0}),e=i([s.CONST(),o("design:paramtypes",[Object])],e)}(a.InjectableMetadata);e.DirectiveMetadata=c;var p=function(t){function e(e){var n=void 0===e?{}:e,r=n.selector,i=n.inputs,o=n.outputs,s=n.properties,a=n.events,c=n.host,p=n.exportAs,l=n.moduleId,h=n.bindings,f=n.providers,d=n.viewBindings,v=n.viewProviders,y=n.changeDetection,m=void 0===y?u.ChangeDetectionStrategy.Default:y,g=n.queries,_=n.templateUrl,b=n.template,P=n.styleUrls,E=n.styles,w=n.directives,C=n.pipes,R=n.encapsulation;t.call(this,{selector:r,inputs:i,outputs:o,properties:s,events:a,host:c,exportAs:p,bindings:h,providers:f,queries:g}),this.changeDetection=m,this._viewProviders=v,this._viewBindings=d,this.templateUrl=_,this.template=b,this.styleUrls=P,this.styles=E,this.directives=w,this.pipes=C,this.encapsulation=R,this.moduleId=l}return r(e,t),Object.defineProperty(e.prototype,"viewProviders",{get:function(){return s.isPresent(this._viewBindings)&&this._viewBindings.length>0?this._viewBindings:this._viewProviders},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"viewBindings",{get:function(){return this.viewProviders},enumerable:!0,configurable:!0}),e=i([s.CONST(),o("design:paramtypes",[Object])],e)}(c);e.ComponentMetadata=p;var l=function(t){function e(e){var n=e.name,r=e.pure;t.call(this),this.name=n,this._pure=r}return r(e,t),Object.defineProperty(e.prototype,"pure",{get:function(){return s.isPresent(this._pure)?this._pure:!0},enumerable:!0,configurable:!0}),e=i([s.CONST(),o("design:paramtypes",[Object])],e)}(a.InjectableMetadata);e.PipeMetadata=l;var h=function(){function t(t){this.bindingPropertyName=t}return t=i([s.CONST(),o("design:paramtypes",[String])],t)}();e.InputMetadata=h;var f=function(){function t(t){this.bindingPropertyName=t}return t=i([s.CONST(),o("design:paramtypes",[String])],t)}();e.OutputMetadata=f;var d=function(){function t(t){this.hostPropertyName=t}return t=i([s.CONST(),o("design:paramtypes",[String])],t)}();e.HostBindingMetadata=d;var v=function(){function t(t,e){this.eventName=t,this.args=e}return t=i([s.CONST(),o("design:paramtypes",[String,Array])],t)}();e.HostListenerMetadata=v},function(t,e,n){"use strict";var r=n(28);e.ChangeDetectionStrategy=r.ChangeDetectionStrategy,e.ChangeDetectorRef=r.ChangeDetectorRef,e.WrappedValue=r.WrappedValue,e.SimpleChange=r.SimpleChange,e.IterableDiffers=r.IterableDiffers,e.KeyValueDiffers=r.KeyValueDiffers,e.CollectionChangeRecord=r.CollectionChangeRecord,e.KeyValueChangeRecord=r.KeyValueChangeRecord},function(t,e,n){"use strict";var r=n(29),i=n(30),o=n(31),s=n(32),a=n(5),u=n(32);e.DefaultKeyValueDifferFactory=u.DefaultKeyValueDifferFactory,e.KeyValueChangeRecord=u.KeyValueChangeRecord;var c=n(30);e.DefaultIterableDifferFactory=c.DefaultIterableDifferFactory,e.CollectionChangeRecord=c.CollectionChangeRecord;var p=n(33);e.ChangeDetectionStrategy=p.ChangeDetectionStrategy,e.CHANGE_DETECTION_STRATEGY_VALUES=p.CHANGE_DETECTION_STRATEGY_VALUES,e.ChangeDetectorState=p.ChangeDetectorState,e.CHANGE_DETECTOR_STATE_VALUES=p.CHANGE_DETECTOR_STATE_VALUES,e.isDefaultChangeDetectionStrategy=p.isDefaultChangeDetectionStrategy;var l=n(34);e.ChangeDetectorRef=l.ChangeDetectorRef;var h=n(29);e.IterableDiffers=h.IterableDiffers;var f=n(31);e.KeyValueDiffers=f.KeyValueDiffers;var d=n(35);e.WrappedValue=d.WrappedValue,e.ValueUnwrapper=d.ValueUnwrapper,e.SimpleChange=d.SimpleChange,e.devModeEqual=d.devModeEqual,e.looseIdentical=d.looseIdentical,e.uninitialized=d.uninitialized,e.keyValDiff=a.CONST_EXPR([a.CONST_EXPR(new s.DefaultKeyValueDifferFactory)]),e.iterableDiff=a.CONST_EXPR([a.CONST_EXPR(new i.DefaultIterableDifferFactory)]),e.defaultIterableDiffers=a.CONST_EXPR(new r.IterableDiffers(e.iterableDiff)),e.defaultKeyValueDiffers=a.CONST_EXPR(new o.KeyValueDiffers(e.keyValDiff))},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);
-return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(12),a=n(15),u=n(6),c=function(){function t(t){this.factories=t}return t.create=function(e,n){if(o.isPresent(n)){var r=a.ListWrapper.clone(n.factories);return e=e.concat(r),new t(e)}return new t(e)},t.extend=function(e){return new u.Provider(t,{useFactory:function(n){if(o.isBlank(n))throw new s.BaseException("Cannot extend IterableDiffers without a parent injector");return t.create(e,n)},deps:[[t,new u.SkipSelfMetadata,new u.OptionalMetadata]]})},t.prototype.find=function(t){var e=this.factories.find(function(e){return e.supports(t)});if(o.isPresent(e))return e;throw new s.BaseException("Cannot find a differ supporting object '"+t+"' of type '"+o.getTypeNameForDebugging(t)+"'")},t=r([o.CONST(),i("design:paramtypes",[Array])],t)}();e.IterableDiffers=c},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(12),a=n(15),u=n(5),c=function(){function t(){}return t.prototype.supports=function(t){return a.isListLikeIterable(t)},t.prototype.create=function(t,e){return new l(e)},t=r([o.CONST(),i("design:paramtypes",[])],t)}();e.DefaultIterableDifferFactory=c;var p=function(t,e){return e},l=function(){function t(t){this._trackByFn=t,this._length=null,this._collection=null,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=u.isPresent(this._trackByFn)?this._trackByFn:p}return Object.defineProperty(t.prototype,"collection",{get:function(){return this._collection},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"length",{get:function(){return this._length},enumerable:!0,configurable:!0}),t.prototype.forEachItem=function(t){var e;for(e=this._itHead;null!==e;e=e._next)t(e)},t.prototype.forEachPreviousItem=function(t){var e;for(e=this._previousItHead;null!==e;e=e._nextPrevious)t(e)},t.prototype.forEachAddedItem=function(t){var e;for(e=this._additionsHead;null!==e;e=e._nextAdded)t(e)},t.prototype.forEachMovedItem=function(t){var e;for(e=this._movesHead;null!==e;e=e._nextMoved)t(e)},t.prototype.forEachRemovedItem=function(t){var e;for(e=this._removalsHead;null!==e;e=e._nextRemoved)t(e)},t.prototype.forEachIdentityChange=function(t){var e;for(e=this._identityChangesHead;null!==e;e=e._nextIdentityChange)t(e)},t.prototype.diff=function(t){if(u.isBlank(t)&&(t=[]),!a.isListLikeIterable(t))throw new s.BaseException("Error trying to diff '"+t+"'");return this.check(t)?this:null},t.prototype.onDestroy=function(){},t.prototype.check=function(t){var e=this;this._reset();var n,r,i,o=this._itHead,s=!1;if(u.isArray(t)){var c=t;for(this._length=t.length,n=0;n"+u.stringify(this.currentIndex)+"]"},t}();e.CollectionChangeRecord=h;var f=function(){function t(){this._head=null,this._tail=null}return t.prototype.add=function(t){null===this._head?(this._head=this._tail=t,t._nextDup=null,t._prevDup=null):(this._tail._nextDup=t,t._prevDup=this._tail,t._nextDup=null,this._tail=t)},t.prototype.get=function(t,e){var n;for(n=this._head;null!==n;n=n._nextDup)if((null===e||eo?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(12),a=n(15),u=n(6),c=function(){function t(t){this.factories=t}return t.create=function(e,n){if(o.isPresent(n)){var r=a.ListWrapper.clone(n.factories);return e=e.concat(r),new t(e)}return new t(e)},t.extend=function(e){return new u.Provider(t,{useFactory:function(n){if(o.isBlank(n))throw new s.BaseException("Cannot extend KeyValueDiffers without a parent injector");return t.create(e,n)},deps:[[t,new u.SkipSelfMetadata,new u.OptionalMetadata]]})},t.prototype.find=function(t){var e=this.factories.find(function(e){return e.supports(t)});if(o.isPresent(e))return e;throw new s.BaseException("Cannot find a differ supporting object '"+t+"'")},t=r([o.CONST(),i("design:paramtypes",[Array])],t)}();e.KeyValueDiffers=c},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(15),s=n(5),a=n(12),u=function(){function t(){}return t.prototype.supports=function(t){return t instanceof Map||s.isJsObject(t)},t.prototype.create=function(t){return new c},t=r([s.CONST(),i("design:paramtypes",[])],t)}();e.DefaultKeyValueDifferFactory=u;var c=function(){function t(){this._records=new Map,this._mapHead=null,this._previousMapHead=null,this._changesHead=null,this._changesTail=null,this._additionsHead=null,this._additionsTail=null,this._removalsHead=null,this._removalsTail=null}return Object.defineProperty(t.prototype,"isDirty",{get:function(){return null!==this._additionsHead||null!==this._changesHead||null!==this._removalsHead},enumerable:!0,configurable:!0}),t.prototype.forEachItem=function(t){var e;for(e=this._mapHead;null!==e;e=e._next)t(e)},t.prototype.forEachPreviousItem=function(t){var e;for(e=this._previousMapHead;null!==e;e=e._nextPrevious)t(e)},t.prototype.forEachChangedItem=function(t){var e;for(e=this._changesHead;null!==e;e=e._nextChanged)t(e)},t.prototype.forEachAddedItem=function(t){var e;for(e=this._additionsHead;null!==e;e=e._nextAdded)t(e)},t.prototype.forEachRemovedItem=function(t){var e;for(e=this._removalsHead;null!==e;e=e._nextRemoved)t(e)},t.prototype.diff=function(t){if(s.isBlank(t)&&(t=o.MapWrapper.createFromPairs([])),!(t instanceof Map||s.isJsObject(t)))throw new a.BaseException("Error trying to diff '"+t+"'");return this.check(t)?this:null},t.prototype.onDestroy=function(){},t.prototype.check=function(t){var e=this;this._reset();var n=this._records,r=this._mapHead,i=null,o=null,a=!1;return this._forEach(t,function(t,u){var c;null!==r&&u===r.key?(c=r,s.looseIdentical(t,r.currentValue)||(r.previousValue=r.currentValue,r.currentValue=t,e._addToChanges(r))):(a=!0,null!==r&&(r._next=null,e._removeFromSeq(i,r),e._addToRemovals(r)),n.has(u)?c=n.get(u):(c=new p(u),n.set(u,c),c.currentValue=t,e._addToAdditions(c))),a&&(e._isInRemovals(c)&&e._removeFromRemovals(c),null==o?e._mapHead=c:o._next=c),i=r,o=c,r=null===r?null:r._next}),this._truncate(i,r),this.isDirty},t.prototype._reset=function(){if(this.isDirty){var t;for(t=this._previousMapHead=this._mapHead;null!==t;t=t._next)t._nextPrevious=t._next;for(t=this._changesHead;null!==t;t=t._nextChanged)t.previousValue=t.currentValue;for(t=this._additionsHead;null!=t;t=t._nextAdded)t.previousValue=t.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=this._removalsTail=null}},t.prototype._truncate=function(t,e){for(;null!==e;){null===t?this._mapHead=null:t._next=null;var n=e._next;this._addToRemovals(e),t=e,e=n}for(var r=this._removalsHead;null!==r;r=r._nextRemoved)r.previousValue=r.currentValue,r.currentValue=null,this._records["delete"](r.key)},t.prototype._isInRemovals=function(t){return t===this._removalsHead||null!==t._nextRemoved||null!==t._prevRemoved},t.prototype._addToRemovals=function(t){null===this._removalsHead?this._removalsHead=this._removalsTail=t:(this._removalsTail._nextRemoved=t,t._prevRemoved=this._removalsTail,this._removalsTail=t)},t.prototype._removeFromSeq=function(t,e){var n=e._next;null===t?this._mapHead=n:t._next=n},t.prototype._removeFromRemovals=function(t){var e=t._prevRemoved,n=t._nextRemoved;null===e?this._removalsHead=n:e._nextRemoved=n,null===n?this._removalsTail=e:n._prevRemoved=e,t._prevRemoved=t._nextRemoved=null},t.prototype._addToAdditions=function(t){null===this._additionsHead?this._additionsHead=this._additionsTail=t:(this._additionsTail._nextAdded=t,this._additionsTail=t)},t.prototype._addToChanges=function(t){null===this._changesHead?this._changesHead=this._changesTail=t:(this._changesTail._nextChanged=t,this._changesTail=t)},t.prototype.toString=function(){var t,e=[],n=[],r=[],i=[],o=[];for(t=this._mapHead;null!==t;t=t._next)e.push(s.stringify(t));for(t=this._previousMapHead;null!==t;t=t._nextPrevious)n.push(s.stringify(t));for(t=this._changesHead;null!==t;t=t._nextChanged)r.push(s.stringify(t));for(t=this._additionsHead;null!==t;t=t._nextAdded)i.push(s.stringify(t));for(t=this._removalsHead;null!==t;t=t._nextRemoved)o.push(s.stringify(t));return"map: "+e.join(", ")+"\nprevious: "+n.join(", ")+"\nadditions: "+i.join(", ")+"\nchanges: "+r.join(", ")+"\nremovals: "+o.join(", ")+"\n"},t.prototype._forEach=function(t,e){t instanceof Map?t.forEach(e):o.StringMapWrapper.forEach(t,e)},t}();e.DefaultKeyValueDiffer=c;var p=function(){function t(t){this.key=t,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._nextAdded=null,this._nextRemoved=null,this._prevRemoved=null,this._nextChanged=null}return t.prototype.toString=function(){return s.looseIdentical(this.previousValue,this.currentValue)?s.stringify(this.key):s.stringify(this.key)+"["+s.stringify(this.previousValue)+"->"+s.stringify(this.currentValue)+"]"},t}();e.KeyValueChangeRecord=p},function(t,e,n){"use strict";function r(t){return i.isBlank(t)||t===s.Default}var i=n(5);!function(t){t[t.NeverChecked=0]="NeverChecked",t[t.CheckedBefore=1]="CheckedBefore",t[t.Errored=2]="Errored"}(e.ChangeDetectorState||(e.ChangeDetectorState={}));var o=e.ChangeDetectorState;!function(t){t[t.CheckOnce=0]="CheckOnce",t[t.Checked=1]="Checked",t[t.CheckAlways=2]="CheckAlways",t[t.Detached=3]="Detached",t[t.OnPush=4]="OnPush",t[t.Default=5]="Default"}(e.ChangeDetectionStrategy||(e.ChangeDetectionStrategy={}));var s=e.ChangeDetectionStrategy;e.CHANGE_DETECTION_STRATEGY_VALUES=[s.CheckOnce,s.Checked,s.CheckAlways,s.Detached,s.OnPush,s.Default],e.CHANGE_DETECTOR_STATE_VALUES=[o.NeverChecked,o.CheckedBefore,o.Errored],e.isDefaultChangeDetectionStrategy=r},function(t,e){"use strict";var n=function(){function t(){}return t}();e.ChangeDetectorRef=n},function(t,e,n){"use strict";function r(t,e){return o.isListLikeIterable(t)&&o.isListLikeIterable(e)?o.areIterablesEqual(t,e,r):o.isListLikeIterable(t)||i.isPrimitive(t)||o.isListLikeIterable(e)||i.isPrimitive(e)?i.looseIdentical(t,e):!0}var i=n(5),o=n(15),s=n(5);e.looseIdentical=s.looseIdentical,e.uninitialized=i.CONST_EXPR(new Object),e.devModeEqual=r;var a=function(){function t(t){this.wrapped=t}return t.wrap=function(e){return new t(e)},t}();e.WrappedValue=a;var u=function(){function t(){this.hasWrappedValue=!1}return t.prototype.unwrap=function(t){return t instanceof a?(this.hasWrappedValue=!0,t.wrapped):t},t.prototype.reset=function(){this.hasWrappedValue=!1},t}();e.ValueUnwrapper=u;var c=function(){function t(t,e){this.previousValue=t,this.currentValue=e}return t.prototype.isFirstChange=function(){return this.previousValue===e.uninitialized},t}();e.SimpleChange=c},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5);!function(t){t[t.Emulated=0]="Emulated",t[t.Native=1]="Native",t[t.None=2]="None"}(e.ViewEncapsulation||(e.ViewEncapsulation={}));var s=e.ViewEncapsulation;e.VIEW_ENCAPSULATION_VALUES=[s.Emulated,s.Native,s.None];var a=function(){function t(t){var e=void 0===t?{}:t,n=e.templateUrl,r=e.template,i=e.directives,o=e.pipes,s=e.encapsulation,a=e.styles,u=e.styleUrls;this.templateUrl=n,this.template=r,this.styleUrls=u,this.styles=a,this.directives=i,this.pipes=o,this.encapsulation=s}return t=r([o.CONST(),i("design:paramtypes",[Object])],t)}();e.ViewMetadata=a},function(t,e,n){"use strict";var r=n(9);e.Class=r.Class},function(t,e,n){"use strict";var r=n(5);e.enableProdMode=r.enableProdMode},function(t,e,n){"use strict";var r=n(5);e.Type=r.Type;var i=n(40);e.EventEmitter=i.EventEmitter;var o=n(12);e.WrappedException=o.WrappedException;var s=n(14);e.ExceptionHandler=s.ExceptionHandler},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=n(5),o=n(41);e.PromiseWrapper=o.PromiseWrapper,e.PromiseCompleter=o.PromiseCompleter;var s=n(42),a=n(43),u=n(58),c=n(42);e.Observable=c.Observable;var p=n(42);e.Subject=p.Subject;var l=function(){function t(){}return t.setTimeout=function(t,e){return i.global.setTimeout(t,e)},t.clearTimeout=function(t){i.global.clearTimeout(t)},t.setInterval=function(t,e){return i.global.setInterval(t,e)},t.clearInterval=function(t){i.global.clearInterval(t)},t}();e.TimerWrapper=l;var h=function(){function t(){}return t.subscribe=function(t,e,n,r){return void 0===r&&(r=function(){}),n="function"==typeof n&&n||i.noop,r="function"==typeof r&&r||i.noop,t.subscribe({next:e,error:n,complete:r})},t.isObservable=function(t){return!!t.subscribe},t.hasSubscribers=function(t){return t.observers.length>0},t.dispose=function(t){t.unsubscribe()},t.callNext=function(t,e){t.next(e)},t.callEmit=function(t,e){t.emit(e)},t.callError=function(t,e){t.error(e)},t.callComplete=function(t){t.complete()},t.fromPromise=function(t){return a.PromiseObservable.create(t)},t.toPromise=function(t){return u.toPromise.call(t)},t}();e.ObservableWrapper=h;var f=function(t){function e(e){void 0===e&&(e=!0),t.call(this),this._isAsync=e}return r(e,t),e.prototype.emit=function(e){t.prototype.next.call(this,e)},e.prototype.next=function(e){t.prototype.next.call(this,e)},e.prototype.subscribe=function(e,n,r){var i,o=function(t){return null},s=function(){return null};return e&&"object"==typeof e?(i=this._isAsync?function(t){setTimeout(function(){return e.next(t)})}:function(t){e.next(t)},e.error&&(o=this._isAsync?function(t){setTimeout(function(){return e.error(t)})}:function(t){e.error(t)}),e.complete&&(s=this._isAsync?function(){setTimeout(function(){return e.complete()})}:function(){e.complete()})):(i=this._isAsync?function(t){setTimeout(function(){return e(t)})}:function(t){e(t)},n&&(o=this._isAsync?function(t){setTimeout(function(){return n(t)})}:function(t){n(t)}),r&&(s=this._isAsync?function(){setTimeout(function(){return r()})}:function(){r()})),t.prototype.subscribe.call(this,i,o,s)},e}(s.Subject);e.EventEmitter=f},function(t,e){"use strict";var n=function(){function t(){var t=this;this.promise=new Promise(function(e,n){t.resolve=e,t.reject=n})}return t}();e.PromiseCompleter=n;var r=function(){function t(){}return t.resolve=function(t){return Promise.resolve(t)},t.reject=function(t,e){return Promise.reject(t)},t.catchError=function(t,e){return t["catch"](e)},t.all=function(t){return 0==t.length?Promise.resolve([]):Promise.all(t)},t.then=function(t,e,n){return t.then(e,n)},t.wrap=function(t){return new Promise(function(e,n){try{e(t())}catch(r){n(r)}})},t.scheduleMicrotask=function(e){t.then(t.resolve(null),e,function(t){})},t.isPromise=function(t){return t instanceof Promise},t.completer=function(){return new n},t}();e.PromiseWrapper=r},function(e,n){e.exports=t},function(t,e,n){"use strict";function r(t){var e=t.value,n=t.subscriber;n.isUnsubscribed||(n.next(e),n.complete())}function i(t){var e=t.err,n=t.subscriber;n.isUnsubscribed||n.error(e)}var o=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},s=n(44),a=n(46),u=function(t){function e(e,n){void 0===n&&(n=null),t.call(this),this.promise=e,this.scheduler=n}return o(e,t),e.create=function(t,n){return void 0===n&&(n=null),new e(t,n)},e.prototype._subscribe=function(t){var e=this,n=this.promise,o=this.scheduler;if(null==o)this._isScalar?t.isUnsubscribed||(t.next(this.value),t.complete()):n.then(function(n){e.value=n,e._isScalar=!0,t.isUnsubscribed||(t.next(n),t.complete())},function(e){t.isUnsubscribed||t.error(e)}).then(null,function(t){s.root.setTimeout(function(){throw t})});else if(this._isScalar){if(!t.isUnsubscribed)return o.schedule(r,0,{value:this.value,subscriber:t})}else n.then(function(n){e.value=n,e._isScalar=!0,t.isUnsubscribed||t.add(o.schedule(r,0,{value:n,subscriber:t}))},function(e){t.isUnsubscribed||t.add(o.schedule(i,0,{err:e,subscriber:t}))}).then(null,function(t){s.root.setTimeout(function(){throw t})})},e}(a.Observable);e.PromiseObservable=u},function(t,e,n){(function(t,n){"use strict";var r={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,undefined:!1};e.root=r[typeof self]&&self||r[typeof window]&&window;var i=(r[typeof e]&&e&&!e.nodeType&&e,r[typeof t]&&t&&!t.nodeType&&t,r[typeof n]&&n);!i||i.global!==i&&i.window!==i||(e.root=i)}).call(e,n(45)(t),function(){return this}())},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children=[],t.webpackPolyfill=1),t}},function(t,e,n){"use strict";var r=n(44),i=n(47),o=n(48),s=n(54),a=n(55),u=function(){function t(t){this._isScalar=!1,t&&(this._subscribe=t)}return t.prototype.lift=function(e){var n=new t;return n.source=this,n.operator=e,n},t.prototype.subscribe=function(t,e,n){var r=this.operator,i=o.toSubscriber(t,e,n);if(r?i.add(this._subscribe(r.call(i))):i.add(this._subscribe(i)),i.syncErrorThrowable&&(i.syncErrorThrowable=!1,i.syncErrorThrown))throw i.syncErrorValue;return i},t.prototype.forEach=function(t,e,n){if(n||(r.root.Rx&&r.root.Rx.config&&r.root.Rx.config.Promise?n=r.root.Rx.config.Promise:r.root.Promise&&(n=r.root.Promise)),!n)throw new Error("no Promise impl found");var i=this;return new n(function(n,r){i.subscribe(function(n){var i=s.tryCatch(t).call(e,n);i===a.errorObject&&r(a.errorObject.e)},r,n)})},t.prototype._subscribe=function(t){return this.source.subscribe(t)},t.prototype[i.SymbolShim.observable]=function(){return this},t.create=function(e){return new t(e)},t}();e.Observable=u},function(t,e,n){"use strict";function r(t){var e=o(t);return a(e,t),u(e),i(e),e}function i(t){t["for"]||(t["for"]=s)}function o(t){return t.Symbol||(t.Symbol=function(t){return"@@Symbol("+t+"):"+p++}),t.Symbol}function s(t){return"@@"+t}function a(t,e){if(!t.iterator)if("function"==typeof t["for"])t.iterator=t["for"]("iterator");else if(e.Set&&"function"==typeof(new e.Set)["@@iterator"])t.iterator="@@iterator";else if(e.Map)for(var n=Object.getOwnPropertyNames(e.Map.prototype),r=0;ro?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},h=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},f=n(60),d=n(5),v=n(6),y=n(62),m=n(40),g=n(15),_=n(63),b=n(64),P=n(12),E=n(75),w=n(71);e.createNgZone=r;var C,R=!1;e.createPlatform=i,e.assertPlatform=o,e.disposePlatform=s,e.getPlatform=a,e.coreBootstrap=u,e.coreLoadAndBootstrap=c;var S=function(){function t(){}return Object.defineProperty(t.prototype,"injector",{get:function(){throw P.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"disposed",{get:function(){throw P.unimplemented()},enumerable:!0,configurable:!0}),t}();e.PlatformRef=S;var O=function(t){function e(e){if(t.call(this),this._injector=e,this._applications=[],this._disposeListeners=[],this._disposed=!1,!R)throw new P.BaseException("Platforms have to be created via `createPlatform`!");var n=e.get(y.PLATFORM_INITIALIZER,null);d.isPresent(n)&&n.forEach(function(t){return t()})}return p(e,t),e.prototype.registerDisposeListener=function(t){this._disposeListeners.push(t)},Object.defineProperty(e.prototype,"injector",{get:function(){return this._injector},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"disposed",{get:function(){return this._disposed},enumerable:!0,configurable:!0}),e.prototype.addApplication=function(t){this._applications.push(t)},e.prototype.dispose=function(){g.ListWrapper.clone(this._applications).forEach(function(t){return t.dispose()}),this._disposeListeners.forEach(function(t){return t()}),this._disposed=!0},e.prototype._applicationDisposed=function(t){g.ListWrapper.remove(this._applications,t)},e=l([v.Injectable(),h("design:paramtypes",[v.Injector])],e)}(S);e.PlatformRef_=O;var T=function(){function t(){}return Object.defineProperty(t.prototype,"injector",{get:function(){return P.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"zone",{get:function(){return P.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"componentTypes",{get:function(){return P.unimplemented()},enumerable:!0,configurable:!0}),t}();e.ApplicationRef=T;var x=function(t){function e(e,n,r){var i=this;t.call(this),this._platform=e,this._zone=n,this._injector=r,this._bootstrapListeners=[],this._disposeListeners=[],this._rootComponents=[],this._rootComponentTypes=[],this._changeDetectorRefs=[],this._runningTick=!1,this._enforceNoNewChanges=!1;var o=r.get(f.NgZone);this._enforceNoNewChanges=d.assertionsEnabled(),o.run(function(){i._exceptionHandler=r.get(P.ExceptionHandler)}),this._asyncInitDonePromise=this.run(function(){var t,e=r.get(y.APP_INITIALIZER,null),n=[];if(d.isPresent(e))for(var o=0;o0?(t=m.PromiseWrapper.all(n).then(function(t){return i._asyncInitDone=!0}),i._asyncInitDone=!1):(i._asyncInitDone=!0,t=m.PromiseWrapper.resolve(!0)),t}),m.ObservableWrapper.subscribe(o.onError,function(t){i._exceptionHandler.call(t.error,t.stackTrace)}),m.ObservableWrapper.subscribe(this._zone.onMicrotaskEmpty,function(t){i._zone.run(function(){i.tick()})})}return p(e,t),e.prototype.registerBootstrapListener=function(t){this._bootstrapListeners.push(t)},e.prototype.registerDisposeListener=function(t){this._disposeListeners.push(t)},e.prototype.registerChangeDetector=function(t){this._changeDetectorRefs.push(t)},e.prototype.unregisterChangeDetector=function(t){g.ListWrapper.remove(this._changeDetectorRefs,t)},e.prototype.waitForAsyncInitializers=function(){return this._asyncInitDonePromise},e.prototype.run=function(t){var e,n=this,r=this.injector.get(f.NgZone),i=m.PromiseWrapper.completer();return r.run(function(){try{e=t(),d.isPromise(e)&&m.PromiseWrapper.then(e,function(t){i.resolve(t)},function(t,e){i.reject(t,e),n._exceptionHandler.call(t,e)})}catch(r){throw n._exceptionHandler.call(r,r.stack),r}}),d.isPromise(e)?i.promise:e},e.prototype.bootstrap=function(t){var e=this;if(!this._asyncInitDone)throw new P.BaseException("Cannot bootstrap as there are still asynchronous initializers running. Wait for them using waitForAsyncInitializers().");return this.run(function(){e._rootComponentTypes.push(t.componentType);var n=t.create(e._injector,[],t.selector);n.onDestroy(function(){e._unloadComponent(n)});var r=n.injector.get(_.Testability,null);d.isPresent(r)&&n.injector.get(_.TestabilityRegistry).registerApplication(n.location.nativeElement,r),e._loadComponent(n);var i=e._injector.get(E.Console);return d.assertionsEnabled()&&i.log("Angular 2 is running in the development mode. Call enableProdMode() to enable the production mode."),n})},e.prototype._loadComponent=function(t){this._changeDetectorRefs.push(t.changeDetectorRef),this.tick(),this._rootComponents.push(t),this._bootstrapListeners.forEach(function(e){return e(t)})},e.prototype._unloadComponent=function(t){g.ListWrapper.contains(this._rootComponents,t)&&(this.unregisterChangeDetector(t.changeDetectorRef),g.ListWrapper.remove(this._rootComponents,t))},Object.defineProperty(e.prototype,"injector",{get:function(){return this._injector},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"zone",{get:function(){return this._zone},enumerable:!0,configurable:!0}),e.prototype.tick=function(){if(this._runningTick)throw new P.BaseException("ApplicationRef.tick is called recursively");var t=e._tickScope();try{this._runningTick=!0,this._changeDetectorRefs.forEach(function(t){return t.detectChanges()}),this._enforceNoNewChanges&&this._changeDetectorRefs.forEach(function(t){return t.checkNoChanges()})}finally{this._runningTick=!1,w.wtfLeave(t)}},e.prototype.dispose=function(){g.ListWrapper.clone(this._rootComponents).forEach(function(t){return t.destroy()}),this._disposeListeners.forEach(function(t){return t()}),this._platform._applicationDisposed(this)},Object.defineProperty(e.prototype,"componentTypes",{get:function(){return this._rootComponentTypes},enumerable:!0,configurable:!0}),e._tickScope=w.wtfCreateScope("ApplicationRef#tick()"),e=l([v.Injectable(),h("design:paramtypes",[O,f.NgZone,v.Injector])],e)}(T);e.ApplicationRef_=x,e.PLATFORM_CORE_PROVIDERS=d.CONST_EXPR([O,d.CONST_EXPR(new v.Provider(S,{useExisting:O}))]),e.APPLICATION_CORE_PROVIDERS=d.CONST_EXPR([d.CONST_EXPR(new v.Provider(f.NgZone,{useFactory:r,deps:d.CONST_EXPR([])})),x,d.CONST_EXPR(new v.Provider(T,{useExisting:x}))])},function(t,e,n){"use strict";var r=n(40),i=n(61),o=n(12),s=n(61);e.NgZoneError=s.NgZoneError;var a=function(){function t(t){var e=this,n=t.enableLongStackTrace,o=void 0===n?!1:n;this._hasPendingMicrotasks=!1,this._hasPendingMacrotasks=!1,this._isStable=!0,this._nesting=0,this._onUnstable=new r.EventEmitter(!1),this._onMicrotaskEmpty=new r.EventEmitter(!1),this._onStable=new r.EventEmitter(!1),this._onErrorEvents=new r.EventEmitter(!1),this._zoneImpl=new i.NgZoneImpl({trace:o,onEnter:function(){e._nesting++,e._isStable&&(e._isStable=!1,e._onUnstable.emit(null))},onLeave:function(){e._nesting--,e._checkStable()},setMicrotask:function(t){e._hasPendingMicrotasks=t,e._checkStable()},setMacrotask:function(t){e._hasPendingMacrotasks=t},onError:function(t){return e._onErrorEvents.emit(t)}})}return t.isInAngularZone=function(){return i.NgZoneImpl.isInAngularZone()},t.assertInAngularZone=function(){if(!i.NgZoneImpl.isInAngularZone())throw new o.BaseException("Expected to be in Angular Zone, but it is not!")},t.assertNotInAngularZone=function(){if(i.NgZoneImpl.isInAngularZone())throw new o.BaseException("Expected to not be in Angular Zone, but it is!")},t.prototype._checkStable=function(){var t=this;if(0==this._nesting&&!this._hasPendingMicrotasks&&!this._isStable)try{this._nesting++,this._onMicrotaskEmpty.emit(null)}finally{if(this._nesting--,!this._hasPendingMicrotasks)try{this.runOutsideAngular(function(){return t._onStable.emit(null)})}finally{this._isStable=!0}}},Object.defineProperty(t.prototype,"onUnstable",{get:function(){return this._onUnstable},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"onMicrotaskEmpty",{get:function(){return this._onMicrotaskEmpty},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"onStable",{get:function(){return this._onStable},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"onError",{get:function(){return this._onErrorEvents},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"hasPendingMicrotasks",{get:function(){return this._hasPendingMicrotasks},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"hasPendingMacrotasks",{get:function(){return this._hasPendingMacrotasks},enumerable:!0,configurable:!0}),t.prototype.run=function(t){return this._zoneImpl.runInner(t)},t.prototype.runGuarded=function(t){return this._zoneImpl.runInnerGuarded(t)},t.prototype.runOutsideAngular=function(t){return this._zoneImpl.runOuter(t)},t}();e.NgZone=a},function(t,e){"use strict";var n=function(){function t(t,e){this.error=t,this.stackTrace=e}return t}();e.NgZoneError=n;var r=function(){function t(t){var e=this,r=t.trace,i=t.onEnter,o=t.onLeave,s=t.setMicrotask,a=t.setMacrotask,u=t.onError;if(this.onEnter=i,this.onLeave=o,this.setMicrotask=s,this.setMacrotask=a,this.onError=u,!Zone)throw new Error("Angular2 needs to be run with Zone.js polyfill.");this.outer=this.inner=Zone.current,Zone.wtfZoneSpec&&(this.inner=this.inner.fork(Zone.wtfZoneSpec)),r&&Zone.longStackTraceZoneSpec&&(this.inner=this.inner.fork(Zone.longStackTraceZoneSpec)),this.inner=this.inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:function(t,n,r,i,o,s){try{return e.onEnter(),t.invokeTask(r,i,o,s)}finally{e.onLeave()}},onInvoke:function(t,n,r,i,o,s,a){try{return e.onEnter(),t.invoke(r,i,o,s,a)}finally{e.onLeave()}},onHasTask:function(t,n,r,i){t.hasTask(r,i),n==r&&("microTask"==i.change?e.setMicrotask(i.microTask):"macroTask"==i.change&&e.setMacrotask(i.macroTask))},onHandleError:function(t,r,i,o){return t.handleError(i,o),e.onError(new n(o,o.stack)),!1}})}return t.isInAngularZone=function(){return Zone.current.get("isAngularZone")===!0},t.prototype.runInner=function(t){return this.inner.run(t)},t.prototype.runInnerGuarded=function(t){return this.inner.runGuarded(t)},t.prototype.runOuter=function(t){return this.outer.run(t)},t}();e.NgZoneImpl=r},function(t,e,n){"use strict";function r(){return""+i()+i()+i()}function i(){return s.StringWrapper.fromCharCode(97+s.Math.floor(25*s.Math.random()))}var o=n(6),s=n(5);e.APP_ID=s.CONST_EXPR(new o.OpaqueToken("AppId")),e.APP_ID_RANDOM_PROVIDER=s.CONST_EXPR(new o.Provider(e.APP_ID,{useFactory:r,deps:[]})),e.PLATFORM_INITIALIZER=s.CONST_EXPR(new o.OpaqueToken("Platform Initializer")),e.APP_INITIALIZER=s.CONST_EXPR(new o.OpaqueToken("Application Initializer")),e.PACKAGE_ROOT_URL=s.CONST_EXPR(new o.OpaqueToken("Application Packages Root URL"))},function(t,e,n){"use strict";function r(t){v=t}var i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=n(6),a=n(15),u=n(5),c=n(12),p=n(60),l=n(40),h=function(){function t(t){this._ngZone=t,this._pendingCount=0,this._isZoneStable=!0,this._didWork=!1,this._callbacks=[],this._watchAngularEvents()}return t.prototype._watchAngularEvents=function(){var t=this;l.ObservableWrapper.subscribe(this._ngZone.onUnstable,function(e){t._didWork=!0,t._isZoneStable=!1}),this._ngZone.runOutsideAngular(function(){l.ObservableWrapper.subscribe(t._ngZone.onStable,function(e){p.NgZone.assertNotInAngularZone(),u.scheduleMicroTask(function(){t._isZoneStable=!0,t._runCallbacksIfReady()})})})},t.prototype.increasePendingRequestCount=function(){return this._pendingCount+=1,this._didWork=!0,this._pendingCount},t.prototype.decreasePendingRequestCount=function(){if(this._pendingCount-=1,this._pendingCount<0)throw new c.BaseException("pending async requests below zero");return this._runCallbacksIfReady(),this._pendingCount},t.prototype.isStable=function(){return this._isZoneStable&&0==this._pendingCount&&!this._ngZone.hasPendingMacrotasks},t.prototype._runCallbacksIfReady=function(){var t=this;this.isStable()?u.scheduleMicroTask(function(){for(;0!==t._callbacks.length;)t._callbacks.pop()(t._didWork);t._didWork=!1}):this._didWork=!0},t.prototype.whenStable=function(t){this._callbacks.push(t),this._runCallbacksIfReady()},t.prototype.getPendingRequestCount=function(){return this._pendingCount},t.prototype.findBindings=function(t,e,n){return[]},t.prototype.findProviders=function(t,e,n){return[]},t=i([s.Injectable(),o("design:paramtypes",[p.NgZone])],t)}();e.Testability=h;var f=function(){function t(){this._applications=new a.Map,v.addToWindow(this)}return t.prototype.registerApplication=function(t,e){this._applications.set(t,e)},t.prototype.getTestability=function(t){return this._applications.get(t)},t.prototype.getAllTestabilities=function(){return a.MapWrapper.values(this._applications)},t.prototype.getAllRootElements=function(){return a.MapWrapper.keys(this._applications)},t.prototype.findTestabilityInTree=function(t,e){return void 0===e&&(e=!0),v.findTestabilityInTree(this,t,e)},t=i([s.Injectable(),o("design:paramtypes",[])],t)}();e.TestabilityRegistry=f;var d=function(){function t(){}return t.prototype.addToWindow=function(t){},t.prototype.findTestabilityInTree=function(t,e,n){return null},t=i([u.CONST(),o("design:paramtypes",[])],t)}();e.setTestabilityGetter=r;var v=u.CONST_EXPR(new d)},function(t,e,n){"use strict";function r(t){return t instanceof h.ComponentFactory}var i=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},o=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},s=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},a=n(6),u=n(5),c=n(12),p=n(40),l=n(18),h=n(65),f=function(){function t(){}return t}();e.ComponentResolver=f;var d=function(t){function e(){t.apply(this,arguments)}return i(e,t),e.prototype.resolveComponent=function(t){var e=l.reflector.annotations(t),n=e.find(r);if(u.isBlank(n))throw new c.BaseException("No precompiled component "+u.stringify(t)+" found");return p.PromiseWrapper.resolve(n)},e.prototype.clearCache=function(){},e=o([a.Injectable(),s("design:paramtypes",[])],e)}(f);e.ReflectorComponentResolver=d},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=n(5),a=n(12),u=n(66),c=function(){function t(){}return Object.defineProperty(t.prototype,"location",{get:function(){return a.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"injector",{get:function(){return a.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"instance",{get:function(){return a.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"hostView",{get:function(){return a.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"changeDetectorRef",{get:function(){return a.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"componentType",{get:function(){return a.unimplemented()},enumerable:!0,configurable:!0}),t}();e.ComponentRef=c;var p=function(t){function e(e,n){t.call(this),this._hostElement=e,this._componentType=n}return r(e,t),Object.defineProperty(e.prototype,"location",{get:function(){return this._hostElement.elementRef},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"injector",{get:function(){return this._hostElement.injector},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"instance",{get:function(){return this._hostElement.component},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"hostView",{get:function(){return this._hostElement.parentView.ref},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"changeDetectorRef",{get:function(){return this.hostView},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"componentType",{get:function(){return this._componentType},enumerable:!0,configurable:!0}),e.prototype.destroy=function(){this._hostElement.parentView.destroy()},e.prototype.onDestroy=function(t){this.hostView.onDestroy(t)},e}(c);e.ComponentRef_=p;var l=function(){function t(t,e,n){this.selector=t,this._viewFactory=e,this._componentType=n}return Object.defineProperty(t.prototype,"componentType",{get:function(){return this._componentType},enumerable:!0,configurable:!0}),t.prototype.create=function(t,e,n){void 0===e&&(e=null),void 0===n&&(n=null);var r=t.get(u.ViewUtils);s.isBlank(e)&&(e=[]);var i=this._viewFactory(r,t,null),o=i.create(e,n);return new p(o,this._componentType)},t=i([s.CONST(),o("design:paramtypes",[String,Function,s.Type])],t)}();e.ComponentFactory=l},function(t,e,n){"use strict";function r(t){return i(t,[])}function i(t,e){for(var n=0;ni;i++)n[i]=r>i?t[i]:D}else n=t;return n}function s(t,e,n,r,i,o,s,u,c,p,l,h,f,d,v,y,m,g,_,b){switch(t){case 1:return e+a(n)+r;case 2:return e+a(n)+r+a(i)+o;case 3:return e+a(n)+r+a(i)+o+a(s)+u;case 4:return e+a(n)+r+a(i)+o+a(s)+u+a(c)+p;case 5:return e+a(n)+r+a(i)+o+a(s)+u+a(c)+p+a(l)+h;case 6:return e+a(n)+r+a(i)+o+a(s)+u+a(c)+p+a(l)+h+a(f)+d;case 7:return e+a(n)+r+a(i)+o+a(s)+u+a(c)+p+a(l)+h+a(f)+d+a(v)+y;case 8:return e+a(n)+r+a(i)+o+a(s)+u+a(c)+p+a(l)+h+a(f)+d+a(v)+y+a(m)+g;case 9:return e+a(n)+r+a(i)+o+a(s)+u+a(c)+p+a(l)+h+a(f)+d+a(v)+y+a(m)+g+a(_)+b;default:throw new O.BaseException("Does not support more than 9 expressions")}}function a(t){return null!=t?t.toString():""}function u(t,e,n){if(t){if(!A.devModeEqual(e,n))throw new x.ExpressionChangedAfterItHasBeenCheckedException(e,n,null);return!1}return!R.looseIdentical(e,n)}function c(t,e){if(t.length!=e.length)return!1;for(var n=0;no?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},w=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},C=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},R=n(5),S=n(15),O=n(12),T=n(67),x=n(73),A=n(28),I=n(6),M=n(74),k=n(62),N=function(){function t(t,e){this._renderer=t,this._appId=e,this._nextCompTypeId=0}return t.prototype.createRenderComponentType=function(t,e,n,r){return new M.RenderComponentType(this._appId+"-"+this._nextCompTypeId++,t,e,n,r)},t.prototype.renderComponent=function(t){return this._renderer.renderComponent(t)},t=E([I.Injectable(),C(1,I.Inject(k.APP_ID)),w("design:paramtypes",[M.RootRenderer,String])],t)}();e.ViewUtils=N,e.flattenNestedViewRenderNodes=r;var D=R.CONST_EXPR([]);e.ensureSlotCount=o,e.MAX_INTERPOLATION_VALUES=9,e.interpolate=s,e.checkBinding=u,e.arrayLooseIdentical=c,e.mapLooseIdentical=p,e.castByValue=l,e.pureProxy1=h,e.pureProxy2=f,e.pureProxy3=d,e.pureProxy4=v,e.pureProxy5=y,e.pureProxy6=m,e.pureProxy7=g,e.pureProxy8=_,e.pureProxy9=b,e.pureProxy10=P},function(t,e,n){"use strict";var r=n(5),i=n(15),o=n(12),s=n(68),a=n(69),u=n(70),c=function(){function t(t,e,n,r){this.index=t,this.parentIndex=e,this.parentView=n,this.nativeElement=r,this.nestedViews=null,this.componentView=null}return Object.defineProperty(t.prototype,"elementRef",{get:function(){return new a.ElementRef(this.nativeElement)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"vcRef",{get:function(){return new u.ViewContainerRef_(this)},enumerable:!0,configurable:!0}),t.prototype.initComponent=function(t,e,n){this.component=t,this.componentConstructorViewQueries=e,this.componentView=n},Object.defineProperty(t.prototype,"parentInjector",{get:function(){return this.parentView.injector(this.parentIndex)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"injector",{get:function(){return this.parentView.injector(this.index)},enumerable:!0,configurable:!0}),t.prototype.mapNestedViews=function(t,e){var n=[];return r.isPresent(this.nestedViews)&&this.nestedViews.forEach(function(r){r.clazz===t&&n.push(e(r))}),n},t.prototype.attachView=function(t,e){if(t.type===s.ViewType.COMPONENT)throw new o.BaseException("Component views can't be moved!");var n=this.nestedViews;null==n&&(n=[],this.nestedViews=n),i.ListWrapper.insert(n,e,t);var a;if(e>0){var u=n[e-1];a=u.lastRootNode}else a=this.nativeElement;r.isPresent(a)&&t.renderer.attachViewAfter(a,t.flatRootNodes),t.addToContentChildren(this)},t.prototype.detachView=function(t){var e=i.ListWrapper.removeAt(this.nestedViews,t);if(e.type===s.ViewType.COMPONENT)throw new o.BaseException("Component views can't be moved!");return e.renderer.detachView(e.flatRootNodes),e.removeFromContentChildren(this),e},t}();e.AppElement=c},function(t,e){"use strict";!function(t){t[t.HOST=0]="HOST",t[t.COMPONENT=1]="COMPONENT",t[t.EMBEDDED=2]="EMBEDDED"}(e.ViewType||(e.ViewType={}));e.ViewType},function(t,e){"use strict";var n=function(){function t(t){this.nativeElement=t}return t}();e.ElementRef=n},function(t,e,n){"use strict";var r=n(15),i=n(12),o=n(5),s=n(71),a=function(){function t(){}return Object.defineProperty(t.prototype,"element",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"injector",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"parentInjector",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"length",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),t}();e.ViewContainerRef=a;var u=function(){function t(t){this._element=t,this._createComponentInContainerScope=s.wtfCreateScope("ViewContainerRef#createComponent()"),this._insertScope=s.wtfCreateScope("ViewContainerRef#insert()"),this._removeScope=s.wtfCreateScope("ViewContainerRef#remove()"),this._detachScope=s.wtfCreateScope("ViewContainerRef#detach()")}return t.prototype.get=function(t){return this._element.nestedViews[t].ref},Object.defineProperty(t.prototype,"length",{get:function(){var t=this._element.nestedViews;return o.isPresent(t)?t.length:0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"element",{get:function(){return this._element.elementRef},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"injector",{get:function(){return this._element.injector},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"parentInjector",{get:function(){return this._element.parentInjector},enumerable:!0,configurable:!0}),t.prototype.createEmbeddedView=function(t,e){void 0===e&&(e=-1);var n=t.createEmbeddedView();return this.insert(n,e),n},t.prototype.createComponent=function(t,e,n,r){void 0===e&&(e=-1),void 0===n&&(n=null),void 0===r&&(r=null);var i=this._createComponentInContainerScope(),a=o.isPresent(n)?n:this._element.parentInjector,u=t.create(a,r);return this.insert(u.hostView,e),s.wtfLeave(i,u)},t.prototype.insert=function(t,e){void 0===e&&(e=-1);var n=this._insertScope();-1==e&&(e=this.length);var r=t;return this._element.attachView(r.internalView,e),s.wtfLeave(n,r)},t.prototype.indexOf=function(t){return r.ListWrapper.indexOf(this._element.nestedViews,t.internalView)},t.prototype.remove=function(t){void 0===t&&(t=-1);var e=this._removeScope();-1==t&&(t=this.length-1);var n=this._element.detachView(t);n.destroy(),s.wtfLeave(e)},t.prototype.detach=function(t){void 0===t&&(t=-1);var e=this._detachScope();-1==t&&(t=this.length-1);var n=this._element.detachView(t);return s.wtfLeave(e,n.ref)},t.prototype.clear=function(){for(var t=this.length-1;t>=0;t--)this.remove(t)},t}();e.ViewContainerRef_=u},function(t,e,n){"use strict";function r(t,e){return null}var i=n(72);e.wtfEnabled=i.detectWTF(),e.wtfCreateScope=e.wtfEnabled?i.createScope:function(t,e){return r},e.wtfLeave=e.wtfEnabled?i.leave:function(t,e){return e},e.wtfStartTimeRange=e.wtfEnabled?i.startTimeRange:function(t,e){return null},e.wtfEndTimeRange=e.wtfEnabled?i.endTimeRange:function(t){return null}},function(t,e,n){"use strict";function r(){var t=p.global.wtf;return t&&(u=t.trace)?(c=u.events,!0):!1}function i(t,e){return void 0===e&&(e=null),c.createScope(t,e)}function o(t,e){return u.leaveScope(t,e),e}function s(t,e){return u.beginTimeRange(t,e)}function a(t){u.endTimeRange(t)}var u,c,p=n(5);e.detectWTF=r,e.createScope=i,e.leave=o,e.startTimeRange=s,e.endTimeRange=a},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=n(12),o=function(t){function e(e,n,r){t.call(this,"Expression has changed after it was checked. "+("Previous value: '"+e+"'. Current value: '"+n+"'"))}return r(e,t),e}(i.BaseException);e.ExpressionChangedAfterItHasBeenCheckedException=o;var s=function(t){function e(e,n,r){t.call(this,"Error in "+r.source,e,n,r)}return r(e,t),e}(i.WrappedException);e.ViewWrappedException=s;var a=function(t){function e(e){t.call(this,"Attempt to use a destroyed view: "+e)}return r(e,t),e}(i.BaseException);e.ViewDestroyedException=a},function(t,e,n){"use strict";var r=n(12),i=function(){function t(t,e,n,r,i){this.id=t,this.templateUrl=e,this.slotCount=n,this.encapsulation=r,this.styles=i}return t}();e.RenderComponentType=i;var o=function(){function t(){}return Object.defineProperty(t.prototype,"injector",{get:function(){return r.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"component",{get:function(){
-return r.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"providerTokens",{get:function(){return r.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"locals",{get:function(){return r.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"source",{get:function(){return r.unimplemented()},enumerable:!0,configurable:!0}),t}();e.RenderDebugInfo=o;var s=function(){function t(){}return t}();e.Renderer=s;var a=function(){function t(){}return t}();e.RootRenderer=a},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(6),s=n(5),a=function(){function t(){}return t.prototype.log=function(t){s.print(t)},t=r([o.Injectable(),i("design:paramtypes",[])],t)}();e.Console=a},function(t,e,n){"use strict";var r=n(60);e.NgZone=r.NgZone,e.NgZoneError=r.NgZoneError},function(t,e,n){"use strict";var r=n(74);e.RootRenderer=r.RootRenderer,e.Renderer=r.Renderer,e.RenderComponentType=r.RenderComponentType},function(t,e,n){"use strict";var r=n(64);e.ComponentResolver=r.ComponentResolver;var i=n(79);e.QueryList=i.QueryList;var o=n(80);e.DynamicComponentLoader=o.DynamicComponentLoader;var s=n(69);e.ElementRef=s.ElementRef;var a=n(81);e.TemplateRef=a.TemplateRef;var u=n(82);e.EmbeddedViewRef=u.EmbeddedViewRef,e.ViewRef=u.ViewRef;var c=n(70);e.ViewContainerRef=c.ViewContainerRef;var p=n(65);e.ComponentRef=p.ComponentRef,e.ComponentFactory=p.ComponentFactory;var l=n(73);e.ExpressionChangedAfterItHasBeenCheckedException=l.ExpressionChangedAfterItHasBeenCheckedException},function(t,e,n){"use strict";var r=n(15),i=n(5),o=n(40),s=function(){function t(){this._dirty=!0,this._results=[],this._emitter=new o.EventEmitter}return Object.defineProperty(t.prototype,"changes",{get:function(){return this._emitter},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"length",{get:function(){return this._results.length},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"first",{get:function(){return r.ListWrapper.first(this._results)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"last",{get:function(){return r.ListWrapper.last(this._results)},enumerable:!0,configurable:!0}),t.prototype.map=function(t){return this._results.map(t)},t.prototype.filter=function(t){return this._results.filter(t)},t.prototype.reduce=function(t,e){return this._results.reduce(t,e)},t.prototype.forEach=function(t){this._results.forEach(t)},t.prototype.toArray=function(){return r.ListWrapper.clone(this._results)},t.prototype[i.getSymbolIterator()]=function(){return this._results[i.getSymbolIterator()]()},t.prototype.toString=function(){return this._results.toString()},t.prototype.reset=function(t){this._results=r.ListWrapper.flatten(t),this._dirty=!1},t.prototype.notifyOnChanges=function(){this._emitter.emit(this)},t.prototype.setDirty=function(){this._dirty=!0},Object.defineProperty(t.prototype,"dirty",{get:function(){return this._dirty},enumerable:!0,configurable:!0}),t}();e.QueryList=s},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=n(6),a=n(64),u=n(5),c=function(){function t(){}return t}();e.DynamicComponentLoader=c;var p=function(t){function e(e){t.call(this),this._compiler=e}return r(e,t),e.prototype.loadAsRoot=function(t,e,n,r,i){return this._compiler.resolveComponent(t).then(function(t){var o=t.create(n,i,u.isPresent(e)?e:t.selector);return u.isPresent(r)&&o.onDestroy(r),o})},e.prototype.loadNextToLocation=function(t,e,n,r){return void 0===n&&(n=null),void 0===r&&(r=null),this._compiler.resolveComponent(t).then(function(t){var i=e.parentInjector,o=u.isPresent(n)&&n.length>0?s.ReflectiveInjector.fromResolvedProviders(n,i):i;return e.createComponent(t,e.length,o,r)})},e=i([s.Injectable(),o("design:paramtypes",[a.ComponentResolver])],e)}(c);e.DynamicComponentLoader_=p},function(t,e){"use strict";var n=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},r=function(){function t(){}return Object.defineProperty(t.prototype,"elementRef",{get:function(){return null},enumerable:!0,configurable:!0}),t}();e.TemplateRef=r;var i=function(t){function e(e,n){t.call(this),this._appElement=e,this._viewFactory=n}return n(e,t),e.prototype.createEmbeddedView=function(){var t=this._viewFactory(this._appElement.parentView.viewUtils,this._appElement.parentInjector,this._appElement);return t.create(null,null),t.ref},Object.defineProperty(e.prototype,"elementRef",{get:function(){return this._appElement.elementRef},enumerable:!0,configurable:!0}),e}(r);e.TemplateRef_=i},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=n(12),o=n(34),s=n(33),a=function(t){function e(){t.apply(this,arguments)}return r(e,t),Object.defineProperty(e.prototype,"changeDetectorRef",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"destroyed",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),e}(o.ChangeDetectorRef);e.ViewRef=a;var u=function(t){function e(){t.apply(this,arguments)}return r(e,t),Object.defineProperty(e.prototype,"rootNodes",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),e}(a);e.EmbeddedViewRef=u;var c=function(){function t(t){this._view=t,this._view=t}return Object.defineProperty(t.prototype,"internalView",{get:function(){return this._view},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"changeDetectorRef",{get:function(){return this},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"rootNodes",{get:function(){return this._view.flatRootNodes},enumerable:!0,configurable:!0}),t.prototype.setLocal=function(t,e){this._view.setLocal(t,e)},t.prototype.hasLocal=function(t){return this._view.hasLocal(t)},Object.defineProperty(t.prototype,"destroyed",{get:function(){return this._view.destroyed},enumerable:!0,configurable:!0}),t.prototype.markForCheck=function(){this._view.markPathToRootAsCheckOnce()},t.prototype.detach=function(){this._view.cdMode=s.ChangeDetectionStrategy.Detached},t.prototype.detectChanges=function(){this._view.detectChanges(!1)},t.prototype.checkNoChanges=function(){this._view.detectChanges(!0)},t.prototype.reattach=function(){this._view.cdMode=s.ChangeDetectionStrategy.CheckAlways,this.markForCheck()},t.prototype.onDestroy=function(t){this._view.disposables.push(t)},t.prototype.destroy=function(){this._view.destroy()},t}();e.ViewRef_=c},function(t,e,n){"use strict";function r(t){return t.map(function(t){return t.nativeElement})}function i(t,e,n){t.childNodes.forEach(function(t){t instanceof v&&(e(t)&&n.push(t),i(t,e,n))})}function o(t,e,n){t instanceof v&&t.childNodes.forEach(function(t){e(t)&&n.push(t),t instanceof v&&o(t,e,n)})}function s(t){return y.get(t)}function a(){return h.MapWrapper.values(y)}function u(t){y.set(t.nativeNode,t)}function c(t){y["delete"](t.nativeNode)}var p=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},l=n(5),h=n(15),f=function(){function t(t,e){this.name=t,this.callback=e}return t}();e.EventListener=f;var d=function(){function t(t,e,n){this._debugInfo=n,this.nativeNode=t,l.isPresent(e)&&e instanceof v?e.addChild(this):this.parent=null,this.listeners=[]}return Object.defineProperty(t.prototype,"injector",{get:function(){return l.isPresent(this._debugInfo)?this._debugInfo.injector:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"componentInstance",{get:function(){return l.isPresent(this._debugInfo)?this._debugInfo.component:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"locals",{get:function(){return l.isPresent(this._debugInfo)?this._debugInfo.locals:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"providerTokens",{get:function(){return l.isPresent(this._debugInfo)?this._debugInfo.providerTokens:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"source",{get:function(){return l.isPresent(this._debugInfo)?this._debugInfo.source:null},enumerable:!0,configurable:!0}),t.prototype.inject=function(t){return this.injector.get(t)},t.prototype.getLocal=function(t){return this.locals[t]},t}();e.DebugNode=d;var v=function(t){function e(e,n,r){t.call(this,e,n,r),this.properties={},this.attributes={},this.childNodes=[],this.nativeElement=e}return p(e,t),e.prototype.addChild=function(t){l.isPresent(t)&&(this.childNodes.push(t),t.parent=this)},e.prototype.removeChild=function(t){var e=this.childNodes.indexOf(t);-1!==e&&(t.parent=null,this.childNodes.splice(e,1))},e.prototype.insertChildrenAfter=function(t,e){var n=this.childNodes.indexOf(t);if(-1!==n){var r=this.childNodes.slice(0,n+1),i=this.childNodes.slice(n+1);this.childNodes=h.ListWrapper.concat(h.ListWrapper.concat(r,e),i);for(var o=0;o0?e[0]:null},e.prototype.queryAll=function(t){var e=[];return i(this,t,e),e},e.prototype.queryAllNodes=function(t){var e=[];return o(this,t,e),e},Object.defineProperty(e.prototype,"children",{get:function(){var t=[];return this.childNodes.forEach(function(n){n instanceof e&&t.push(n)}),t},enumerable:!0,configurable:!0}),e.prototype.triggerEventHandler=function(t,e){this.listeners.forEach(function(n){n.name==t&&n.callback(e)})},e}(d);e.DebugElement=v,e.asNativeElements=r;var y=new Map;e.getDebugNode=s,e.getAllDebugNodes=a,e.indexDebugNode=u,e.removeDebugNodeFromIndex=c},function(t,e,n){"use strict";var r=n(6),i=n(5);e.PLATFORM_DIRECTIVES=i.CONST_EXPR(new r.OpaqueToken("Platform Directives")),e.PLATFORM_PIPES=i.CONST_EXPR(new r.OpaqueToken("Platform Pipes"))},function(t,e,n){"use strict";function r(){return a.reflector}var i=n(5),o=n(6),s=n(75),a=n(18),u=n(20),c=n(63),p=n(59);e.PLATFORM_COMMON_PROVIDERS=i.CONST_EXPR([p.PLATFORM_CORE_PROVIDERS,new o.Provider(a.Reflector,{useFactory:r,deps:[]}),new o.Provider(u.ReflectorReader,{useExisting:a.Reflector}),c.TestabilityRegistry,s.Console])},function(t,e,n){"use strict";var r=n(5),i=n(6),o=n(62),s=n(59),a=n(28),u=n(66),c=n(64),p=n(64),l=n(80),h=n(80);e.APPLICATION_COMMON_PROVIDERS=r.CONST_EXPR([s.APPLICATION_CORE_PROVIDERS,new i.Provider(c.ComponentResolver,{useClass:p.ReflectorComponentResolver}),o.APP_ID_RANDOM_PROVIDER,u.ViewUtils,new i.Provider(a.IterableDiffers,{useValue:a.defaultIterableDiffers}),new i.Provider(a.KeyValueDiffers,{useValue:a.defaultKeyValueDiffers}),new i.Provider(l.DynamicComponentLoader,{useClass:h.DynamicComponentLoader_})])},function(t,e,n){"use strict";function r(t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n])}r(n(88)),r(n(102)),r(n(112)),r(n(136))},function(t,e,n){"use strict";var r=n(89);e.AsyncPipe=r.AsyncPipe;var i=n(91);e.DatePipe=i.DatePipe;var o=n(93);e.JsonPipe=o.JsonPipe;var s=n(94);e.SlicePipe=s.SlicePipe;var a=n(95);e.LowerCasePipe=a.LowerCasePipe;var u=n(96);e.NumberPipe=u.NumberPipe,e.DecimalPipe=u.DecimalPipe,e.PercentPipe=u.PercentPipe,e.CurrencyPipe=u.CurrencyPipe;var c=n(97);e.UpperCasePipe=c.UpperCasePipe;var p=n(98);e.ReplacePipe=p.ReplacePipe;var l=n(99);e.I18nPluralPipe=l.I18nPluralPipe;var h=n(100);e.I18nSelectPipe=h.I18nSelectPipe;var f=n(101);e.COMMON_PIPES=f.COMMON_PIPES},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(40),a=n(2),u=n(90),c=function(){function t(){}return t.prototype.createSubscription=function(t,e){return s.ObservableWrapper.subscribe(t,e,function(t){throw t})},t.prototype.dispose=function(t){s.ObservableWrapper.dispose(t)},t.prototype.onDestroy=function(t){s.ObservableWrapper.dispose(t)},t}(),p=function(){function t(){}return t.prototype.createSubscription=function(t,e){return t.then(e)},t.prototype.dispose=function(t){},t.prototype.onDestroy=function(t){},t}(),l=new p,h=new c,f=function(){function t(t){this._latestValue=null,this._latestReturnedValue=null,this._subscription=null,this._obj=null,this._strategy=null,this._ref=t}return t.prototype.ngOnDestroy=function(){o.isPresent(this._subscription)&&this._dispose()},t.prototype.transform=function(t){return o.isBlank(this._obj)?(o.isPresent(t)&&this._subscribe(t),this._latestReturnedValue=this._latestValue,this._latestValue):t!==this._obj?(this._dispose(),this.transform(t)):this._latestValue===this._latestReturnedValue?this._latestReturnedValue:(this._latestReturnedValue=this._latestValue,a.WrappedValue.wrap(this._latestValue))},t.prototype._subscribe=function(t){var e=this;this._obj=t,this._strategy=this._selectStrategy(t),this._subscription=this._strategy.createSubscription(t,function(n){return e._updateLatestValue(t,n)})},t.prototype._selectStrategy=function(e){if(o.isPromise(e))return l;if(s.ObservableWrapper.isObservable(e))return h;throw new u.InvalidPipeArgumentException(t,e)},t.prototype._dispose=function(){this._strategy.dispose(this._subscription),this._latestValue=null,this._latestReturnedValue=null,this._subscription=null,this._obj=null},t.prototype._updateLatestValue=function(t,e){t===this._obj&&(this._latestValue=e,this._ref.markForCheck())},t=r([a.Pipe({name:"async",pure:!1}),a.Injectable(),i("design:paramtypes",[a.ChangeDetectorRef])],t)}();e.AsyncPipe=f},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=n(5),o=n(12),s=function(t){function e(e,n){t.call(this,"Invalid argument '"+n+"' for pipe '"+i.stringify(e)+"'")}return r(e,t),e}(o.BaseException);e.InvalidPipeArgumentException=s},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(92),a=n(2),u=n(15),c=n(90),p="en-US",l=function(){function t(){}return t.prototype.transform=function(e,n){if(void 0===n&&(n="mediumDate"),o.isBlank(e))return null;if(!this.supports(e))throw new c.InvalidPipeArgumentException(t,e);return o.isNumber(e)&&(e=o.DateWrapper.fromMillis(e)),u.StringMapWrapper.contains(t._ALIASES,n)&&(n=u.StringMapWrapper.get(t._ALIASES,n)),s.DateFormatter.format(e,p,n)},t.prototype.supports=function(t){return o.isDate(t)||o.isNumber(t)},t._ALIASES={medium:"yMMMdjms","short":"yMdjm",fullDate:"yMMMMEEEEd",longDate:"yMMMMd",mediumDate:"yMMMd",shortDate:"yMd",mediumTime:"jms",shortTime:"jm"},t=r([o.CONST(),a.Pipe({name:"date",pure:!0}),a.Injectable(),i("design:paramtypes",[])],t)}();e.DatePipe=l},function(t,e){"use strict";function n(t){return 2==t?"2-digit":"numeric"}function r(t){return 4>t?"short":"long"}function i(t){for(var e,i={},o=0;o=3?i.month=r(s):i.month=n(s);break;case"d":i.day=n(s);break;case"E":i.weekday=r(s);break;case"j":i.hour=n(s);break;case"h":i.hour=n(s),i.hour12=!0;break;case"H":i.hour=n(s),i.hour12=!1;break;case"m":i.minute=n(s);break;case"s":i.second=n(s);break;case"z":i.timeZoneName="long";break;case"Z":i.timeZoneName="short"}o=e}return i}!function(t){t[t.Decimal=0]="Decimal",t[t.Percent=1]="Percent",t[t.Currency=2]="Currency"}(e.NumberFormatStyle||(e.NumberFormatStyle={}));var o=e.NumberFormatStyle,s=function(){function t(){}return t.format=function(t,e,n,r){var i=void 0===r?{}:r,s=i.minimumIntegerDigits,a=void 0===s?1:s,u=i.minimumFractionDigits,c=void 0===u?0:u,p=i.maximumFractionDigits,l=void 0===p?3:p,h=i.currency,f=i.currencyAsSymbol,d=void 0===f?!1:f,v={minimumIntegerDigits:a,minimumFractionDigits:c,maximumFractionDigits:l};return v.style=o[n].toLowerCase(),n==o.Currency&&(v.currency=h,v.currencyDisplay=d?"symbol":"code"),new Intl.NumberFormat(e,v).format(t)},t}();e.NumberFormatter=s;var a=new Map,u=function(){function t(){}return t.format=function(t,e,n){var r=e+n;if(a.has(r))return a.get(r).format(t);var o=new Intl.DateTimeFormat(e,i(n));return a.set(r,o),o.format(t)},t}();e.DateFormatter=u},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(2),a=function(){function t(){}return t.prototype.transform=function(t){return o.Json.stringify(t)},t=r([o.CONST(),s.Pipe({name:"json",pure:!1}),s.Injectable(),i("design:paramtypes",[])],t)}();e.JsonPipe=a},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(15),a=n(2),u=n(90),c=function(){function t(){}return t.prototype.transform=function(e,n,r){if(void 0===r&&(r=null),!this.supports(e))throw new u.InvalidPipeArgumentException(t,e);return o.isBlank(e)?e:o.isString(e)?o.StringWrapper.slice(e,n,r):s.ListWrapper.slice(e,n,r)},t.prototype.supports=function(t){return o.isString(t)||o.isArray(t)},t=r([a.Pipe({name:"slice",pure:!1}),a.Injectable(),i("design:paramtypes",[])],t)}();e.SlicePipe=c},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(2),a=n(90),u=function(){function t(){}return t.prototype.transform=function(e){if(o.isBlank(e))return e;if(!o.isString(e))throw new a.InvalidPipeArgumentException(t,e);return e.toLowerCase()},t=r([o.CONST(),s.Pipe({name:"lowercase"}),s.Injectable(),i("design:paramtypes",[])],t)}();e.LowerCasePipe=u},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=n(5),a=n(12),u=n(92),c=n(2),p=n(90),l="en-US",h=s.RegExpWrapper.create("^(\\d+)?\\.((\\d+)(\\-(\\d+))?)?$"),f=function(){function t(){}return t._format=function(e,n,r,i,o){if(void 0===i&&(i=null),void 0===o&&(o=!1),s.isBlank(e))return null;if(!s.isNumber(e))throw new p.InvalidPipeArgumentException(t,e);var c=1,f=0,d=3;if(s.isPresent(r)){var v=s.RegExpWrapper.firstMatch(h,r);if(s.isBlank(v))throw new a.BaseException(r+" is not a valid digit info for number pipes");s.isPresent(v[1])&&(c=s.NumberWrapper.parseIntAutoRadix(v[1])),s.isPresent(v[3])&&(f=s.NumberWrapper.parseIntAutoRadix(v[3])),s.isPresent(v[5])&&(d=s.NumberWrapper.parseIntAutoRadix(v[5]))}return u.NumberFormatter.format(e,l,n,{minimumIntegerDigits:c,minimumFractionDigits:f,maximumFractionDigits:d,currency:i,currencyAsSymbol:o})},t=i([s.CONST(),c.Injectable(),o("design:paramtypes",[])],t)}();e.NumberPipe=f;var d=function(t){function e(){t.apply(this,arguments)}return r(e,t),e.prototype.transform=function(t,e){return void 0===e&&(e=null),f._format(t,u.NumberFormatStyle.Decimal,e)},e=i([s.CONST(),c.Pipe({name:"number"}),c.Injectable(),o("design:paramtypes",[])],e)}(f);e.DecimalPipe=d;var v=function(t){function e(){t.apply(this,arguments)}return r(e,t),e.prototype.transform=function(t,e){return void 0===e&&(e=null),f._format(t,u.NumberFormatStyle.Percent,e)},e=i([s.CONST(),c.Pipe({name:"percent"}),c.Injectable(),o("design:paramtypes",[])],e)}(f);e.PercentPipe=v;var y=function(t){function e(){t.apply(this,arguments)}return r(e,t),e.prototype.transform=function(t,e,n,r){return void 0===e&&(e="USD"),void 0===n&&(n=!1),void 0===r&&(r=null),f._format(t,u.NumberFormatStyle.Currency,r,e,n)},e=i([s.CONST(),c.Pipe({name:"currency"}),c.Injectable(),o("design:paramtypes",[])],e)}(f);e.CurrencyPipe=y},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(2),a=n(90),u=function(){function t(){}return t.prototype.transform=function(e){if(o.isBlank(e))return e;if(!o.isString(e))throw new a.InvalidPipeArgumentException(t,e);return e.toUpperCase()},t=r([o.CONST(),s.Pipe({name:"uppercase"}),s.Injectable(),i("design:paramtypes",[])],t)}();e.UpperCasePipe=u},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(2),a=n(90),u=function(){function t(){}return t.prototype.transform=function(e,n,r){if(o.isBlank(e))return e;if(!this._supportedInput(e))throw new a.InvalidPipeArgumentException(t,e);var i=e.toString();if(!this._supportedPattern(n))throw new a.InvalidPipeArgumentException(t,n);if(!this._supportedReplacement(r))throw new a.InvalidPipeArgumentException(t,r);if(o.isFunction(r)){var s=o.isString(n)?o.RegExpWrapper.create(n):n;return o.StringWrapper.replaceAllMapped(i,s,r)}return n instanceof RegExp?o.StringWrapper.replaceAll(i,n,r):o.StringWrapper.replace(i,n,r)},t.prototype._supportedInput=function(t){return o.isString(t)||o.isNumber(t)},t.prototype._supportedPattern=function(t){return o.isString(t)||t instanceof RegExp},t.prototype._supportedReplacement=function(t){return o.isString(t)||o.isFunction(t)},t=r([s.Pipe({name:"replace"}),s.Injectable(),i("design:paramtypes",[])],t)}();e.ReplacePipe=u},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(2),a=n(90),u=o.RegExpWrapper.create("#"),c=function(){function t(){}return t.prototype.transform=function(e,n){var r,i;if(!o.isStringMap(n))throw new a.InvalidPipeArgumentException(t,n);return r=0===e||1===e?"="+e:"other",i=o.isPresent(e)?e.toString():"",o.StringWrapper.replaceAll(n[r],u,i)},t=r([o.CONST(),s.Pipe({name:"i18nPlural",pure:!0}),s.Injectable(),i("design:paramtypes",[])],t)}();e.I18nPluralPipe=c},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(15),a=n(2),u=n(90),c=function(){function t(){}return t.prototype.transform=function(e,n){if(!o.isStringMap(n))throw new u.InvalidPipeArgumentException(t,n);return s.StringMapWrapper.contains(n,e)?n[e]:n.other},t=r([o.CONST(),a.Pipe({name:"i18nSelect",pure:!0}),a.Injectable(),i("design:paramtypes",[])],t)}();e.I18nSelectPipe=c},function(t,e,n){"use strict";var r=n(89),i=n(97),o=n(95),s=n(93),a=n(94),u=n(91),c=n(96),p=n(98),l=n(99),h=n(100),f=n(5);e.COMMON_PIPES=f.CONST_EXPR([r.AsyncPipe,i.UpperCasePipe,o.LowerCasePipe,s.JsonPipe,a.SlicePipe,c.DecimalPipe,c.PercentPipe,c.CurrencyPipe,u.DatePipe,p.ReplacePipe,l.I18nPluralPipe,h.I18nSelectPipe])},function(t,e,n){"use strict";function r(t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n])}var i=n(103);e.NgClass=i.NgClass;var o=n(104);e.NgFor=o.NgFor;var s=n(105);e.NgIf=s.NgIf;var a=n(106);e.NgTemplateOutlet=a.NgTemplateOutlet;var u=n(107);e.NgStyle=u.NgStyle;var c=n(108);e.NgSwitch=c.NgSwitch,e.NgSwitchWhen=c.NgSwitchWhen,e.NgSwitchDefault=c.NgSwitchDefault;var p=n(109);e.NgPlural=p.NgPlural,e.NgPluralCase=p.NgPluralCase,e.NgLocalization=p.NgLocalization,r(n(110));var l=n(111);e.CORE_DIRECTIVES=l.CORE_DIRECTIVES},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(5),s=n(2),a=n(15),u=function(){function t(t,e,n,r){this._iterableDiffers=t,this._keyValueDiffers=e,this._ngEl=n,this._renderer=r,this._initialClasses=[]}return Object.defineProperty(t.prototype,"initialClasses",{set:function(t){this._applyInitialClasses(!0),this._initialClasses=o.isPresent(t)&&o.isString(t)?t.split(" "):[],this._applyInitialClasses(!1),this._applyClasses(this._rawClass,!1)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"rawClass",{set:function(t){this._cleanupClasses(this._rawClass),o.isString(t)&&(t=t.split(" ")),this._rawClass=t,this._iterableDiffer=null,this._keyValueDiffer=null,o.isPresent(t)&&(a.isListLikeIterable(t)?this._iterableDiffer=this._iterableDiffers.find(t).create(null):this._keyValueDiffer=this._keyValueDiffers.find(t).create(null))},enumerable:!0,configurable:!0}),t.prototype.ngDoCheck=function(){if(o.isPresent(this._iterableDiffer)){var t=this._iterableDiffer.diff(this._rawClass);o.isPresent(t)&&this._applyIterableChanges(t)}if(o.isPresent(this._keyValueDiffer)){var t=this._keyValueDiffer.diff(this._rawClass);o.isPresent(t)&&this._applyKeyValueChanges(t)}},t.prototype.ngOnDestroy=function(){this._cleanupClasses(this._rawClass)},t.prototype._cleanupClasses=function(t){this._applyClasses(t,!0),this._applyInitialClasses(!1)},t.prototype._applyKeyValueChanges=function(t){var e=this;t.forEachAddedItem(function(t){e._toggleClass(t.key,t.currentValue)}),t.forEachChangedItem(function(t){e._toggleClass(t.key,t.currentValue)}),t.forEachRemovedItem(function(t){t.previousValue&&e._toggleClass(t.key,!1)})},t.prototype._applyIterableChanges=function(t){var e=this;t.forEachAddedItem(function(t){e._toggleClass(t.item,!0)}),t.forEachRemovedItem(function(t){e._toggleClass(t.item,!1)})},t.prototype._applyInitialClasses=function(t){var e=this;this._initialClasses.forEach(function(n){return e._toggleClass(n,!t)})},t.prototype._applyClasses=function(t,e){var n=this;o.isPresent(t)&&(o.isArray(t)?t.forEach(function(t){return n._toggleClass(t,!e)}):t instanceof Set?t.forEach(function(t){return n._toggleClass(t,!e)}):a.StringMapWrapper.forEach(t,function(t,r){o.isPresent(t)&&n._toggleClass(r,!e)}))},t.prototype._toggleClass=function(t,e){if(t=t.trim(),t.length>0)if(t.indexOf(" ")>-1)for(var n=t.split(/\s+/g),r=0,i=n.length;i>r;r++)this._renderer.setElementClass(this._ngEl.nativeElement,n[r],e);else this._renderer.setElementClass(this._ngEl.nativeElement,t,e)},t=r([s.Directive({selector:"[ngClass]",inputs:["rawClass: ngClass","initialClasses: class"]}),i("design:paramtypes",[s.IterableDiffers,s.KeyValueDiffers,s.ElementRef,s.Renderer])],t)}();e.NgClass=u},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(5),a=n(12),u=function(){function t(t,e,n,r){this._viewContainer=t,this._templateRef=e,this._iterableDiffers=n,this._cdr=r}return Object.defineProperty(t.prototype,"ngForOf",{
-set:function(t){if(this._ngForOf=t,s.isBlank(this._differ)&&s.isPresent(t))try{this._differ=this._iterableDiffers.find(t).create(this._cdr,this._ngForTrackBy)}catch(e){throw new a.BaseException("Cannot find a differ supporting object '"+t+"' of type '"+s.getTypeNameForDebugging(t)+"'. NgFor only supports binding to Iterables such as Arrays.")}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"ngForTemplate",{set:function(t){s.isPresent(t)&&(this._templateRef=t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"ngForTrackBy",{set:function(t){this._ngForTrackBy=t},enumerable:!0,configurable:!0}),t.prototype.ngDoCheck=function(){if(s.isPresent(this._differ)){var t=this._differ.diff(this._ngForOf);s.isPresent(t)&&this._applyChanges(t)}},t.prototype._applyChanges=function(t){var e=this,n=[];t.forEachRemovedItem(function(t){return n.push(new c(t,null))}),t.forEachMovedItem(function(t){return n.push(new c(t,null))});var r=this._bulkRemove(n);t.forEachAddedItem(function(t){return r.push(new c(t,null))}),this._bulkInsert(r);for(var i=0;ii;i++){var s=this._viewContainer.get(i);s.setLocal("first",0===i),s.setLocal("last",i===o-1)}t.forEachIdentityChange(function(t){var n=e._viewContainer.get(t.currentIndex);n.setLocal("$implicit",t.item)})},t.prototype._perViewChange=function(t,e){t.setLocal("$implicit",e.item),t.setLocal("index",e.currentIndex),t.setLocal("even",e.currentIndex%2==0),t.setLocal("odd",e.currentIndex%2==1)},t.prototype._bulkRemove=function(t){t.sort(function(t,e){return t.record.previousIndex-e.record.previousIndex});for(var e=[],n=t.length-1;n>=0;n--){var r=t[n];s.isPresent(r.record.currentIndex)?(r.view=this._viewContainer.detach(r.record.previousIndex),e.push(r)):this._viewContainer.remove(r.record.previousIndex)}return e},t.prototype._bulkInsert=function(t){t.sort(function(t,e){return t.record.currentIndex-e.record.currentIndex});for(var e=0;eo?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(5),a=function(){function t(t,e){this._viewContainer=t,this._templateRef=e,this._prevCondition=null}return Object.defineProperty(t.prototype,"ngIf",{set:function(t){!t||!s.isBlank(this._prevCondition)&&this._prevCondition?t||!s.isBlank(this._prevCondition)&&!this._prevCondition||(this._prevCondition=!1,this._viewContainer.clear()):(this._prevCondition=!0,this._viewContainer.createEmbeddedView(this._templateRef))},enumerable:!0,configurable:!0}),t=r([o.Directive({selector:"[ngIf]",inputs:["ngIf"]}),i("design:paramtypes",[o.ViewContainerRef,o.TemplateRef])],t)}();e.NgIf=a},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(5),a=function(){function t(t){this._viewContainerRef=t}return Object.defineProperty(t.prototype,"ngTemplateOutlet",{set:function(t){s.isPresent(this._insertedViewRef)&&this._viewContainerRef.remove(this._viewContainerRef.indexOf(this._insertedViewRef)),s.isPresent(t)&&(this._insertedViewRef=this._viewContainerRef.createEmbeddedView(t))},enumerable:!0,configurable:!0}),r([o.Input(),i("design:type",o.TemplateRef),i("design:paramtypes",[o.TemplateRef])],t.prototype,"ngTemplateOutlet",null),t=r([o.Directive({selector:"[ngTemplateOutlet]"}),i("design:paramtypes",[o.ViewContainerRef])],t)}();e.NgTemplateOutlet=a},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(5),a=function(){function t(t,e,n){this._differs=t,this._ngEl=e,this._renderer=n}return Object.defineProperty(t.prototype,"rawStyle",{set:function(t){this._rawStyle=t,s.isBlank(this._differ)&&s.isPresent(t)&&(this._differ=this._differs.find(this._rawStyle).create(null))},enumerable:!0,configurable:!0}),t.prototype.ngDoCheck=function(){if(s.isPresent(this._differ)){var t=this._differ.diff(this._rawStyle);s.isPresent(t)&&this._applyChanges(t)}},t.prototype._applyChanges=function(t){var e=this;t.forEachAddedItem(function(t){e._setStyle(t.key,t.currentValue)}),t.forEachChangedItem(function(t){e._setStyle(t.key,t.currentValue)}),t.forEachRemovedItem(function(t){e._setStyle(t.key,null)})},t.prototype._setStyle=function(t,e){this._renderer.setElementStyle(this._ngEl.nativeElement,t,e)},t=r([o.Directive({selector:"[ngStyle]",inputs:["rawStyle: ngStyle"]}),i("design:paramtypes",[o.KeyValueDiffers,o.ElementRef,o.Renderer])],t)}();e.NgStyle=a},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},s=n(2),a=n(5),u=n(15),c=a.CONST_EXPR(new Object),p=function(){function t(t,e){this._viewContainerRef=t,this._templateRef=e}return t.prototype.create=function(){this._viewContainerRef.createEmbeddedView(this._templateRef)},t.prototype.destroy=function(){this._viewContainerRef.clear()},t}();e.SwitchView=p;var l=function(){function t(){this._useDefault=!1,this._valueViews=new u.Map,this._activeViews=[]}return Object.defineProperty(t.prototype,"ngSwitch",{set:function(t){this._emptyAllActiveViews(),this._useDefault=!1;var e=this._valueViews.get(t);a.isBlank(e)&&(this._useDefault=!0,e=a.normalizeBlank(this._valueViews.get(c))),this._activateViews(e),this._switchValue=t},enumerable:!0,configurable:!0}),t.prototype._onWhenValueChanged=function(t,e,n){this._deregisterView(t,n),this._registerView(e,n),t===this._switchValue?(n.destroy(),u.ListWrapper.remove(this._activeViews,n)):e===this._switchValue&&(this._useDefault&&(this._useDefault=!1,this._emptyAllActiveViews()),n.create(),this._activeViews.push(n)),0!==this._activeViews.length||this._useDefault||(this._useDefault=!0,this._activateViews(this._valueViews.get(c)))},t.prototype._emptyAllActiveViews=function(){for(var t=this._activeViews,e=0;eo?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},s=n(2),a=n(5),u=n(15),c=n(108),p="other",l=function(){function t(){}return t}();e.NgLocalization=l;var h=function(){function t(t,e,n){this.value=t,this._view=new c.SwitchView(n,e)}return t=r([s.Directive({selector:"[ngPluralCase]"}),o(0,s.Attribute("ngPluralCase")),i("design:paramtypes",[String,s.TemplateRef,s.ViewContainerRef])],t)}();e.NgPluralCase=h;var f=function(){function t(t){this._localization=t,this._caseViews=new u.Map,this.cases=null}return Object.defineProperty(t.prototype,"ngPlural",{set:function(t){this._switchValue=t,this._updateView()},enumerable:!0,configurable:!0}),t.prototype.ngAfterContentInit=function(){var t=this;this.cases.forEach(function(e){t._caseViews.set(t._formatValue(e),e._view)}),this._updateView()},t.prototype._updateView=function(){this._clearViews();var t=this._caseViews.get(this._switchValue);a.isPresent(t)||(t=this._getCategoryView(this._switchValue)),this._activateView(t)},t.prototype._clearViews=function(){a.isPresent(this._activeView)&&this._activeView.destroy()},t.prototype._activateView=function(t){a.isPresent(t)&&(this._activeView=t,this._activeView.create())},t.prototype._getCategoryView=function(t){var e=this._localization.getPluralCategory(t),n=this._caseViews.get(e);return a.isPresent(n)?n:this._caseViews.get(p)},t.prototype._isValueView=function(t){return"="===t.value[0]},t.prototype._formatValue=function(t){return this._isValueView(t)?this._stripValue(t.value):t.value},t.prototype._stripValue=function(t){return a.NumberWrapper.parseInt(t.substring(1),10)},r([s.ContentChildren(h),i("design:type",s.QueryList)],t.prototype,"cases",void 0),r([s.Input(),i("design:type",Number),i("design:paramtypes",[Number])],t.prototype,"ngPlural",null),t=r([s.Directive({selector:"[ngPlural]"}),i("design:paramtypes",[l])],t)}();e.NgPlural=f},function(t,e){"use strict"},function(t,e,n){"use strict";var r=n(5),i=n(103),o=n(104),s=n(105),a=n(106),u=n(107),c=n(108),p=n(109);e.CORE_DIRECTIVES=r.CONST_EXPR([i.NgClass,o.NgFor,s.NgIf,a.NgTemplateOutlet,u.NgStyle,c.NgSwitch,c.NgSwitchWhen,c.NgSwitchDefault,p.NgPlural,p.NgPluralCase])},function(t,e,n){"use strict";var r=n(113);e.AbstractControl=r.AbstractControl,e.Control=r.Control,e.ControlGroup=r.ControlGroup,e.ControlArray=r.ControlArray;var i=n(114);e.AbstractControlDirective=i.AbstractControlDirective;var o=n(115);e.ControlContainer=o.ControlContainer;var s=n(116);e.NgControlName=s.NgControlName;var a=n(127);e.NgFormControl=a.NgFormControl;var u=n(128);e.NgModel=u.NgModel;var c=n(117);e.NgControl=c.NgControl;var p=n(129);e.NgControlGroup=p.NgControlGroup;var l=n(130);e.NgFormModel=l.NgFormModel;var h=n(131);e.NgForm=h.NgForm;var f=n(118);e.NG_VALUE_ACCESSOR=f.NG_VALUE_ACCESSOR;var d=n(121);e.DefaultValueAccessor=d.DefaultValueAccessor;var v=n(132);e.NgControlStatus=v.NgControlStatus;var y=n(123);e.CheckboxControlValueAccessor=y.CheckboxControlValueAccessor;var m=n(124);e.NgSelectOption=m.NgSelectOption,e.SelectControlValueAccessor=m.SelectControlValueAccessor;var g=n(133);e.FORM_DIRECTIVES=g.FORM_DIRECTIVES,e.RadioButtonState=g.RadioButtonState;var _=n(120);e.NG_VALIDATORS=_.NG_VALIDATORS,e.NG_ASYNC_VALIDATORS=_.NG_ASYNC_VALIDATORS,e.Validators=_.Validators;var b=n(134);e.RequiredValidator=b.RequiredValidator,e.MinLengthValidator=b.MinLengthValidator,e.MaxLengthValidator=b.MaxLengthValidator,e.PatternValidator=b.PatternValidator;var P=n(135);e.FormBuilder=P.FormBuilder;var E=n(135),w=n(125),C=n(5);e.FORM_PROVIDERS=C.CONST_EXPR([E.FormBuilder,w.RadioControlRegistry]),e.FORM_BINDINGS=e.FORM_PROVIDERS},function(t,e,n){"use strict";function r(t){return t instanceof l}function i(t,e){return a.isBlank(e)?null:(e instanceof Array||(e=e.split("/")),e instanceof Array&&p.ListWrapper.isEmpty(e)?null:e.reduce(function(t,e){if(t instanceof f)return a.isPresent(t.controls[e])?t.controls[e]:null;if(t instanceof d){var n=e;return a.isPresent(t.at(n))?t.at(n):null}return null},t))}function o(t){return c.PromiseWrapper.isPromise(t)?u.ObservableWrapper.fromPromise(t):t}var s=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},a=n(5),u=n(40),c=n(41),p=n(15);e.VALID="VALID",e.INVALID="INVALID",e.PENDING="PENDING",e.isControl=r;var l=function(){function t(t,e){this.validator=t,this.asyncValidator=e,this._pristine=!0,this._touched=!1}return Object.defineProperty(t.prototype,"value",{get:function(){return this._value},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"status",{get:function(){return this._status},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"valid",{get:function(){return this._status===e.VALID},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"errors",{get:function(){return this._errors},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"pristine",{get:function(){return this._pristine},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"dirty",{get:function(){return!this.pristine},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"touched",{get:function(){return this._touched},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"untouched",{get:function(){return!this._touched},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"valueChanges",{get:function(){return this._valueChanges},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"statusChanges",{get:function(){return this._statusChanges},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"pending",{get:function(){return this._status==e.PENDING},enumerable:!0,configurable:!0}),t.prototype.markAsTouched=function(){this._touched=!0},t.prototype.markAsDirty=function(t){var e=(void 0===t?{}:t).onlySelf;e=a.normalizeBool(e),this._pristine=!1,a.isPresent(this._parent)&&!e&&this._parent.markAsDirty({onlySelf:e})},t.prototype.markAsPending=function(t){var n=(void 0===t?{}:t).onlySelf;n=a.normalizeBool(n),this._status=e.PENDING,a.isPresent(this._parent)&&!n&&this._parent.markAsPending({onlySelf:n})},t.prototype.setParent=function(t){this._parent=t},t.prototype.updateValueAndValidity=function(t){var n=void 0===t?{}:t,r=n.onlySelf,i=n.emitEvent;r=a.normalizeBool(r),i=a.isPresent(i)?i:!0,this._updateValue(),this._errors=this._runValidator(),this._status=this._calculateStatus(),(this._status==e.VALID||this._status==e.PENDING)&&this._runAsyncValidator(i),i&&(u.ObservableWrapper.callEmit(this._valueChanges,this._value),u.ObservableWrapper.callEmit(this._statusChanges,this._status)),a.isPresent(this._parent)&&!r&&this._parent.updateValueAndValidity({onlySelf:r,emitEvent:i})},t.prototype._runValidator=function(){return a.isPresent(this.validator)?this.validator(this):null},t.prototype._runAsyncValidator=function(t){var n=this;if(a.isPresent(this.asyncValidator)){this._status=e.PENDING,this._cancelExistingSubscription();var r=o(this.asyncValidator(this));this._asyncValidationSubscription=u.ObservableWrapper.subscribe(r,function(e){return n.setErrors(e,{emitEvent:t})})}},t.prototype._cancelExistingSubscription=function(){a.isPresent(this._asyncValidationSubscription)&&u.ObservableWrapper.dispose(this._asyncValidationSubscription)},t.prototype.setErrors=function(t,e){var n=(void 0===e?{}:e).emitEvent;n=a.isPresent(n)?n:!0,this._errors=t,this._status=this._calculateStatus(),n&&u.ObservableWrapper.callEmit(this._statusChanges,this._status),a.isPresent(this._parent)&&this._parent._updateControlsErrors()},t.prototype.find=function(t){return i(this,t)},t.prototype.getError=function(t,e){void 0===e&&(e=null);var n=a.isPresent(e)&&!p.ListWrapper.isEmpty(e)?this.find(e):this;return a.isPresent(n)&&a.isPresent(n._errors)?p.StringMapWrapper.get(n._errors,t):null},t.prototype.hasError=function(t,e){return void 0===e&&(e=null),a.isPresent(this.getError(t,e))},Object.defineProperty(t.prototype,"root",{get:function(){for(var t=this;a.isPresent(t._parent);)t=t._parent;return t},enumerable:!0,configurable:!0}),t.prototype._updateControlsErrors=function(){this._status=this._calculateStatus(),a.isPresent(this._parent)&&this._parent._updateControlsErrors()},t.prototype._initObservables=function(){this._valueChanges=new u.EventEmitter,this._statusChanges=new u.EventEmitter},t.prototype._calculateStatus=function(){return a.isPresent(this._errors)?e.INVALID:this._anyControlsHaveStatus(e.PENDING)?e.PENDING:this._anyControlsHaveStatus(e.INVALID)?e.INVALID:e.VALID},t}();e.AbstractControl=l;var h=function(t){function e(e,n,r){void 0===e&&(e=null),void 0===n&&(n=null),void 0===r&&(r=null),t.call(this,n,r),this._value=e,this.updateValueAndValidity({onlySelf:!0,emitEvent:!1}),this._initObservables()}return s(e,t),e.prototype.updateValue=function(t,e){var n=void 0===e?{}:e,r=n.onlySelf,i=n.emitEvent,o=n.emitModelToViewChange;o=a.isPresent(o)?o:!0,this._value=t,a.isPresent(this._onChange)&&o&&this._onChange(this._value),this.updateValueAndValidity({onlySelf:r,emitEvent:i})},e.prototype._updateValue=function(){},e.prototype._anyControlsHaveStatus=function(t){return!1},e.prototype.registerOnChange=function(t){this._onChange=t},e}(l);e.Control=h;var f=function(t){function e(e,n,r,i){void 0===n&&(n=null),void 0===r&&(r=null),void 0===i&&(i=null),t.call(this,r,i),this.controls=e,this._optionals=a.isPresent(n)?n:{},this._initObservables(),this._setParentForControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!1})}return s(e,t),e.prototype.addControl=function(t,e){this.controls[t]=e,e.setParent(this)},e.prototype.removeControl=function(t){p.StringMapWrapper["delete"](this.controls,t)},e.prototype.include=function(t){p.StringMapWrapper.set(this._optionals,t,!0),this.updateValueAndValidity()},e.prototype.exclude=function(t){p.StringMapWrapper.set(this._optionals,t,!1),this.updateValueAndValidity()},e.prototype.contains=function(t){var e=p.StringMapWrapper.contains(this.controls,t);return e&&this._included(t)},e.prototype._setParentForControls=function(){var t=this;p.StringMapWrapper.forEach(this.controls,function(e,n){e.setParent(t)})},e.prototype._updateValue=function(){this._value=this._reduceValue()},e.prototype._anyControlsHaveStatus=function(t){var e=this,n=!1;return p.StringMapWrapper.forEach(this.controls,function(r,i){n=n||e.contains(i)&&r.status==t}),n},e.prototype._reduceValue=function(){return this._reduceChildren({},function(t,e,n){return t[n]=e.value,t})},e.prototype._reduceChildren=function(t,e){var n=this,r=t;return p.StringMapWrapper.forEach(this.controls,function(t,i){n._included(i)&&(r=e(r,t,i))}),r},e.prototype._included=function(t){var e=p.StringMapWrapper.contains(this._optionals,t);return!e||p.StringMapWrapper.get(this._optionals,t)},e}(l);e.ControlGroup=f;var d=function(t){function e(e,n,r){void 0===n&&(n=null),void 0===r&&(r=null),t.call(this,n,r),this.controls=e,this._initObservables(),this._setParentForControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!1})}return s(e,t),e.prototype.at=function(t){return this.controls[t]},e.prototype.push=function(t){this.controls.push(t),t.setParent(this),this.updateValueAndValidity()},e.prototype.insert=function(t,e){p.ListWrapper.insert(this.controls,t,e),e.setParent(this),this.updateValueAndValidity()},e.prototype.removeAt=function(t){p.ListWrapper.removeAt(this.controls,t),this.updateValueAndValidity()},Object.defineProperty(e.prototype,"length",{get:function(){return this.controls.length},enumerable:!0,configurable:!0}),e.prototype._updateValue=function(){this._value=this.controls.map(function(t){return t.value})},e.prototype._anyControlsHaveStatus=function(t){return this.controls.some(function(e){return e.status==t})},e.prototype._setParentForControls=function(){var t=this;this.controls.forEach(function(e){e.setParent(t)})},e}(l);e.ControlArray=d},function(t,e,n){"use strict";var r=n(5),i=n(12),o=function(){function t(){}return Object.defineProperty(t.prototype,"control",{get:function(){return i.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return r.isPresent(this.control)?this.control.value:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"valid",{get:function(){return r.isPresent(this.control)?this.control.valid:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"errors",{get:function(){return r.isPresent(this.control)?this.control.errors:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"pristine",{get:function(){return r.isPresent(this.control)?this.control.pristine:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"dirty",{get:function(){return r.isPresent(this.control)?this.control.dirty:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"touched",{get:function(){return r.isPresent(this.control)?this.control.touched:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"untouched",{get:function(){return r.isPresent(this.control)?this.control.untouched:null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"path",{get:function(){return null},enumerable:!0,configurable:!0}),t}();e.AbstractControlDirective=o},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=n(114),o=function(t){function e(){t.apply(this,arguments)}return r(e,t),Object.defineProperty(e.prototype,"formDirective",{get:function(){return null},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"path",{get:function(){return null},enumerable:!0,configurable:!0}),e}(i.AbstractControlDirective);e.ControlContainer=o},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},a=n(5),u=n(40),c=n(2),p=n(115),l=n(117),h=n(118),f=n(119),d=n(120),v=a.CONST_EXPR(new c.Provider(l.NgControl,{useExisting:c.forwardRef(function(){return y})})),y=function(t){function e(e,n,r,i){t.call(this),this._parent=e,this._validators=n,this._asyncValidators=r,this.update=new u.EventEmitter,this._added=!1,this.valueAccessor=f.selectValueAccessor(this,i)}return r(e,t),e.prototype.ngOnChanges=function(t){this._added||(this.formDirective.addControl(this),this._added=!0),f.isPropertyUpdated(t,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))},e.prototype.ngOnDestroy=function(){this.formDirective.removeControl(this)},e.prototype.viewToModelUpdate=function(t){this.viewModel=t,u.ObservableWrapper.callEmit(this.update,t)},Object.defineProperty(e.prototype,"path",{get:function(){return f.controlPath(this.name,this._parent)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"formDirective",{get:function(){return this._parent.formDirective},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"validator",{get:function(){return f.composeValidators(this._validators)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"asyncValidator",{get:function(){return f.composeAsyncValidators(this._asyncValidators)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"control",{get:function(){return this.formDirective.getControl(this)},enumerable:!0,configurable:!0}),e=i([c.Directive({selector:"[ngControl]",bindings:[v],inputs:["name: ngControl","model: ngModel"],outputs:["update: ngModelChange"],exportAs:"ngForm"}),s(0,c.Host()),s(0,c.SkipSelf()),s(1,c.Optional()),s(1,c.Self()),s(1,c.Inject(d.NG_VALIDATORS)),s(2,c.Optional()),s(2,c.Self()),s(2,c.Inject(d.NG_ASYNC_VALIDATORS)),s(3,c.Optional()),s(3,c.Self()),s(3,c.Inject(h.NG_VALUE_ACCESSOR)),o("design:paramtypes",[p.ControlContainer,Array,Array,Array])],e)}(l.NgControl);e.NgControlName=y},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=n(114),o=n(12),s=function(t){function e(){t.apply(this,arguments),this.name=null,this.valueAccessor=null}return r(e,t),Object.defineProperty(e.prototype,"validator",{get:function(){return o.unimplemented()},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"asyncValidator",{get:function(){return o.unimplemented()},enumerable:!0,configurable:!0}),e}(i.AbstractControlDirective);e.NgControl=s},function(t,e,n){"use strict";var r=n(2),i=n(5);e.NG_VALUE_ACCESSOR=i.CONST_EXPR(new r.OpaqueToken("NgValueAccessor"))},function(t,e,n){"use strict";function r(t,e){var n=l.ListWrapper.clone(e.path);return n.push(t),n}function i(t,e){h.isBlank(t)&&s(e,"Cannot find control"),h.isBlank(e.valueAccessor)&&s(e,"No value accessor for"),t.validator=d.Validators.compose([t.validator,e.validator]),t.asyncValidator=d.Validators.composeAsync([t.asyncValidator,e.asyncValidator]),e.valueAccessor.writeValue(t.value),e.valueAccessor.registerOnChange(function(n){e.viewToModelUpdate(n),t.updateValue(n,{emitModelToViewChange:!1}),t.markAsDirty()}),t.registerOnChange(function(t){return e.valueAccessor.writeValue(t)}),e.valueAccessor.registerOnTouched(function(){return t.markAsTouched()})}function o(t,e){h.isBlank(t)&&s(e,"Cannot find control"),t.validator=d.Validators.compose([t.validator,e.validator]),t.asyncValidator=d.Validators.composeAsync([t.asyncValidator,e.asyncValidator])}function s(t,e){var n=t.path.join(" -> ");throw new f.BaseException(e+" '"+n+"'")}function a(t){return h.isPresent(t)?d.Validators.compose(t.map(b.normalizeValidator)):null}function u(t){return h.isPresent(t)?d.Validators.composeAsync(t.map(b.normalizeAsyncValidator)):null}function c(t,e){if(!l.StringMapWrapper.contains(t,"model"))return!1;var n=t.model;return n.isFirstChange()?!0:!h.looseIdentical(e,n.currentValue)}function p(t,e){if(h.isBlank(e))return null;var n,r,i;return e.forEach(function(e){h.hasConstructor(e,v.DefaultValueAccessor)?n=e:h.hasConstructor(e,m.CheckboxControlValueAccessor)||h.hasConstructor(e,y.NumberValueAccessor)||h.hasConstructor(e,g.SelectControlValueAccessor)||h.hasConstructor(e,_.RadioControlValueAccessor)?(h.isPresent(r)&&s(t,"More than one built-in value accessor matches"),r=e):(h.isPresent(i)&&s(t,"More than one custom value accessor matches"),i=e)}),h.isPresent(i)?i:h.isPresent(r)?r:h.isPresent(n)?n:(s(t,"No valid value accessor for"),null)}var l=n(15),h=n(5),f=n(12),d=n(120),v=n(121),y=n(122),m=n(123),g=n(124),_=n(125),b=n(126);e.controlPath=r,e.setUpControl=i,e.setUpControlGroup=o,e.composeValidators=a,e.composeAsyncValidators=u,e.isPropertyUpdated=c,e.selectValueAccessor=p},function(t,e,n){"use strict";function r(t){return u.PromiseWrapper.isPromise(t)?t:c.ObservableWrapper.toPromise(t)}function i(t,e){return e.map(function(e){return e(t)})}function o(t,e){return e.map(function(e){return e(t)})}function s(t){var e=t.reduce(function(t,e){return a.isPresent(e)?p.StringMapWrapper.merge(t,e):t},{});return p.StringMapWrapper.isEmpty(e)?null:e}var a=n(5),u=n(41),c=n(40),p=n(15),l=n(2);e.NG_VALIDATORS=a.CONST_EXPR(new l.OpaqueToken("NgValidators")),e.NG_ASYNC_VALIDATORS=a.CONST_EXPR(new l.OpaqueToken("NgAsyncValidators"));var h=function(){function t(){}return t.required=function(t){return a.isBlank(t.value)||a.isString(t.value)&&""==t.value?{required:!0}:null},t.minLength=function(e){return function(n){if(a.isPresent(t.required(n)))return null;var r=n.value;return r.lengthe?{maxlength:{requiredLength:e,actualLength:r.length}}:null}},t.pattern=function(e){return function(n){if(a.isPresent(t.required(n)))return null;var r=new RegExp("^"+e+"$"),i=n.value;return r.test(i)?null:{pattern:{requiredPattern:"^"+e+"$",actualValue:i}}}},t.nullValidator=function(t){return null},t.compose=function(t){if(a.isBlank(t))return null;var e=t.filter(a.isPresent);return 0==e.length?null:function(t){return s(i(t,e))}},t.composeAsync=function(t){if(a.isBlank(t))return null;var e=t.filter(a.isPresent);return 0==e.length?null:function(t){var n=o(t,e).map(r);return u.PromiseWrapper.all(n).then(s)}},t}();e.Validators=h},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(118),a=n(5),u=a.CONST_EXPR(new o.Provider(s.NG_VALUE_ACCESSOR,{useExisting:o.forwardRef(function(){return c}),multi:!0})),c=function(){function t(t,e){this._renderer=t,this._elementRef=e,this.onChange=function(t){},this.onTouched=function(){}}return t.prototype.writeValue=function(t){var e=a.isBlank(t)?"":t;this._renderer.setElementProperty(this._elementRef.nativeElement,"value",e)},t.prototype.registerOnChange=function(t){this.onChange=t},t.prototype.registerOnTouched=function(t){this.onTouched=t},t=r([o.Directive({selector:"input:not([type=checkbox])[ngControl],textarea[ngControl],input:not([type=checkbox])[ngFormControl],textarea[ngFormControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]",
-host:{"(input)":"onChange($event.target.value)","(blur)":"onTouched()"},bindings:[u]}),i("design:paramtypes",[o.Renderer,o.ElementRef])],t)}();e.DefaultValueAccessor=c},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(118),a=n(5),u=a.CONST_EXPR(new o.Provider(s.NG_VALUE_ACCESSOR,{useExisting:o.forwardRef(function(){return c}),multi:!0})),c=function(){function t(t,e){this._renderer=t,this._elementRef=e,this.onChange=function(t){},this.onTouched=function(){}}return t.prototype.writeValue=function(t){this._renderer.setElementProperty(this._elementRef.nativeElement,"value",t)},t.prototype.registerOnChange=function(t){this.onChange=function(e){t(""==e?null:a.NumberWrapper.parseFloat(e))}},t.prototype.registerOnTouched=function(t){this.onTouched=t},t=r([o.Directive({selector:"input[type=number][ngControl],input[type=number][ngFormControl],input[type=number][ngModel]",host:{"(change)":"onChange($event.target.value)","(input)":"onChange($event.target.value)","(blur)":"onTouched()"},bindings:[u]}),i("design:paramtypes",[o.Renderer,o.ElementRef])],t)}();e.NumberValueAccessor=c},function(t,e,n){"use strict";var r=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(118),a=n(5),u=a.CONST_EXPR(new o.Provider(s.NG_VALUE_ACCESSOR,{useExisting:o.forwardRef(function(){return c}),multi:!0})),c=function(){function t(t,e){this._renderer=t,this._elementRef=e,this.onChange=function(t){},this.onTouched=function(){}}return t.prototype.writeValue=function(t){this._renderer.setElementProperty(this._elementRef.nativeElement,"checked",t)},t.prototype.registerOnChange=function(t){this.onChange=t},t.prototype.registerOnTouched=function(t){this.onTouched=t},t=r([o.Directive({selector:"input[type=checkbox][ngControl],input[type=checkbox][ngFormControl],input[type=checkbox][ngModel]",host:{"(change)":"onChange($event.target.checked)","(blur)":"onTouched()"},providers:[u]}),i("design:paramtypes",[o.Renderer,o.ElementRef])],t)}();e.CheckboxControlValueAccessor=c},function(t,e,n){"use strict";function r(t,e){return p.isBlank(t)?""+e:(p.isPrimitive(e)||(e="Object"),p.StringWrapper.slice(t+": "+e,0,50))}function i(t){return t.split(":")[0]}var o=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},s=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},a=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},u=n(2),c=n(118),p=n(5),l=n(15),h=p.CONST_EXPR(new u.Provider(c.NG_VALUE_ACCESSOR,{useExisting:u.forwardRef(function(){return f}),multi:!0})),f=function(){function t(t,e){this._renderer=t,this._elementRef=e,this._optionMap=new Map,this._idCounter=0,this.onChange=function(t){},this.onTouched=function(){}}return t.prototype.writeValue=function(t){this.value=t;var e=r(this._getOptionId(t),t);this._renderer.setElementProperty(this._elementRef.nativeElement,"value",e)},t.prototype.registerOnChange=function(t){var e=this;this.onChange=function(n){t(e._getOptionValue(n))}},t.prototype.registerOnTouched=function(t){this.onTouched=t},t.prototype._registerOption=function(){return(this._idCounter++).toString()},t.prototype._getOptionId=function(t){for(var e=0,n=l.MapWrapper.keys(this._optionMap);eo?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},i=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},o=n(2),s=n(118),a=n(117),u=n(5),c=n(15),p=u.CONST_EXPR(new o.Provider(s.NG_VALUE_ACCESSOR,{useExisting:o.forwardRef(function(){return f}),multi:!0})),l=function(){function t(){this._accessors=[]}return t.prototype.add=function(t,e){this._accessors.push([t,e])},t.prototype.remove=function(t){for(var e=-1,n=0;no?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},a=n(5),u=n(15),c=n(40),p=n(2),l=n(117),h=n(120),f=n(118),d=n(119),v=a.CONST_EXPR(new p.Provider(l.NgControl,{useExisting:p.forwardRef(function(){return y})})),y=function(t){function e(e,n,r){t.call(this),this._validators=e,this._asyncValidators=n,this.update=new c.EventEmitter,this.valueAccessor=d.selectValueAccessor(this,r)}return r(e,t),e.prototype.ngOnChanges=function(t){this._isControlChanged(t)&&(d.setUpControl(this.form,this),this.form.updateValueAndValidity({emitEvent:!1})),d.isPropertyUpdated(t,this.viewModel)&&(this.form.updateValue(this.model),this.viewModel=this.model)},Object.defineProperty(e.prototype,"path",{get:function(){return[]},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"validator",{get:function(){return d.composeValidators(this._validators)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"asyncValidator",{get:function(){return d.composeAsyncValidators(this._asyncValidators)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"control",{get:function(){return this.form},enumerable:!0,configurable:!0}),e.prototype.viewToModelUpdate=function(t){this.viewModel=t,c.ObservableWrapper.callEmit(this.update,t)},e.prototype._isControlChanged=function(t){return u.StringMapWrapper.contains(t,"form")},e=i([p.Directive({selector:"[ngFormControl]",bindings:[v],inputs:["form: ngFormControl","model: ngModel"],outputs:["update: ngModelChange"],exportAs:"ngForm"}),s(0,p.Optional()),s(0,p.Self()),s(0,p.Inject(h.NG_VALIDATORS)),s(1,p.Optional()),s(1,p.Self()),s(1,p.Inject(h.NG_ASYNC_VALIDATORS)),s(2,p.Optional()),s(2,p.Self()),s(2,p.Inject(f.NG_VALUE_ACCESSOR)),o("design:paramtypes",[Array,Array,Array])],e)}(l.NgControl);e.NgFormControl=y},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},a=n(5),u=n(40),c=n(2),p=n(118),l=n(117),h=n(113),f=n(120),d=n(119),v=a.CONST_EXPR(new c.Provider(l.NgControl,{useExisting:c.forwardRef(function(){return y})})),y=function(t){function e(e,n,r){t.call(this),this._validators=e,this._asyncValidators=n,this._control=new h.Control,this._added=!1,this.update=new u.EventEmitter,this.valueAccessor=d.selectValueAccessor(this,r)}return r(e,t),e.prototype.ngOnChanges=function(t){this._added||(d.setUpControl(this._control,this),this._control.updateValueAndValidity({emitEvent:!1}),this._added=!0),d.isPropertyUpdated(t,this.viewModel)&&(this._control.updateValue(this.model),this.viewModel=this.model)},Object.defineProperty(e.prototype,"control",{get:function(){return this._control},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"path",{get:function(){return[]},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"validator",{get:function(){return d.composeValidators(this._validators)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"asyncValidator",{get:function(){return d.composeAsyncValidators(this._asyncValidators)},enumerable:!0,configurable:!0}),e.prototype.viewToModelUpdate=function(t){this.viewModel=t,u.ObservableWrapper.callEmit(this.update,t)},e=i([c.Directive({selector:"[ngModel]:not([ngControl]):not([ngFormControl])",bindings:[v],inputs:["model: ngModel"],outputs:["update: ngModelChange"],exportAs:"ngForm"}),s(0,c.Optional()),s(0,c.Self()),s(0,c.Inject(f.NG_VALIDATORS)),s(1,c.Optional()),s(1,c.Self()),s(1,c.Inject(f.NG_ASYNC_VALIDATORS)),s(2,c.Optional()),s(2,c.Self()),s(2,c.Inject(p.NG_VALUE_ACCESSOR)),o("design:paramtypes",[Array,Array,Array])],e)}(l.NgControl);e.NgModel=y},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},a=n(2),u=n(5),c=n(115),p=n(119),l=n(120),h=u.CONST_EXPR(new a.Provider(c.ControlContainer,{useExisting:a.forwardRef(function(){return f})})),f=function(t){function e(e,n,r){t.call(this),this._validators=n,this._asyncValidators=r,this._parent=e}return r(e,t),e.prototype.ngOnInit=function(){this.formDirective.addControlGroup(this)},e.prototype.ngOnDestroy=function(){this.formDirective.removeControlGroup(this)},Object.defineProperty(e.prototype,"control",{get:function(){return this.formDirective.getControlGroup(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"path",{get:function(){return p.controlPath(this.name,this._parent)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"formDirective",{get:function(){return this._parent.formDirective},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"validator",{get:function(){return p.composeValidators(this._validators)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"asyncValidator",{get:function(){return p.composeAsyncValidators(this._asyncValidators)},enumerable:!0,configurable:!0}),e=i([a.Directive({selector:"[ngControlGroup]",providers:[h],inputs:["name: ngControlGroup"],exportAs:"ngForm"}),s(0,a.Host()),s(0,a.SkipSelf()),s(1,a.Optional()),s(1,a.Self()),s(1,a.Inject(l.NG_VALIDATORS)),s(2,a.Optional()),s(2,a.Self()),s(2,a.Inject(l.NG_ASYNC_VALIDATORS)),o("design:paramtypes",[c.ControlContainer,Array,Array])],e)}(c.ControlContainer);e.NgControlGroup=f},function(t,e,n){"use strict";var r=this&&this.__extends||function(t,e){function n(){this.constructor=t}for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)},i=this&&this.__decorate||function(t,e,n,r){var i,o=arguments.length,s=3>o?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(i=t[a])&&(s=(3>o?i(s):o>3?i(e,n,s):i(e,n))||s);return o>3&&s&&Object.defineProperty(e,n,s),s},o=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},s=this&&this.__param||function(t,e){return function(n,r){e(n,r,t)}},a=n(5),u=n(15),c=n(12),p=n(40),l=n(2),h=n(115),f=n(119),d=n(120),v=a.CONST_EXPR(new l.Provider(h.ControlContainer,{useExisting:l.forwardRef(function(){return y})})),y=function(t){function e(e,n){t.call(this),this._validators=e,this._asyncValidators=n,this.form=null,this.directives=[],this.ngSubmit=new p.EventEmitter}return r(e,t),e.prototype.ngOnChanges=function(t){if(this._checkFormPresent(),u.StringMapWrapper.contains(t,"form")){var e=f.composeValidators(this._validators);this.form.validator=d.Validators.compose([this.form.validator,e]);var n=f.composeAsyncValidators(this._asyncValidators);this.form.asyncValidator=d.Validators.composeAsync([this.form.asyncValidator,n]),this.form.updateValueAndValidity({onlySelf:!0,emitEvent:!1})}this._updateDomValue()},Object.defineProperty(e.prototype,"formDirective",{get:function(){return this},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"control",{get:function(){return this.form},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"path",{get:function(){return[]},enumerable:!0,configurable:!0}),e.prototype.addControl=function(t){var e=this.form.find(t.path);f.setUpControl(e,t),e.updateValueAndValidity({emitEvent:!1}),this.directives.push(t)},e.prototype.getControl=function(t){return this.form.find(t.path)},e.prototype.removeControl=function(t){u.ListWrapper.remove(this.directives,t)},e.prototype.addControlGroup=function(t){var e=this.form.find(t.path);f.setUpControlGroup(e,t),e.updateValueAndValidity({emitEvent:!1})},e.prototype.removeControlGroup=function(t){},e.prototype.getControlGroup=function(t){return this.form.find(t.path)},e.prototype.updateModel=function(t,e){var n=this.form.find(t.path);n.updateValue(e)},e.prototype.onSubmit=function(){return p.ObservableWrapper.callEmit(this.ngSubmit,null),!1},e.prototype._updateDomValue=function(){var t=this;this.directives.forEach(function(e){var n=t.form.find(e.path);e.valueAccessor.writeValue(n.value)})},e.prototype._checkFormPresent=function(){if(a.isBlank(this.form))throw new c.BaseException('ngFormModel expects a form. Please pass one in. Example: