Socket
Socket
Sign inDemoInstall

@angular/upgrade

Package Overview
Dependencies
Maintainers
1
Versions
844
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@angular/upgrade - npm Package Compare versions

Comparing version 4.3.0-rc.0 to 4.3.0

4

@angular/upgrade/static.es5.js
/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -587,3 +587,3 @@ * License: MIT

*/
var VERSION = new Version('4.3.0-rc.0');
var VERSION = new Version('4.3.0');
/**

@@ -590,0 +590,0 @@ * @license

/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -598,3 +598,3 @@ * License: MIT

*/
var VERSION = new Version('4.3.0-rc.0');
var VERSION = new Version('4.3.0');

@@ -601,0 +601,0 @@ /**

/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -13,3 +13,3 @@ * License: MIT

/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -598,3 +598,3 @@ * License: MIT

*/
var VERSION = new _angular_core.Version('4.3.0-rc.0');
var VERSION = new _angular_core.Version('4.3.0');
/**

@@ -601,0 +601,0 @@ * @license

/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -7,3 +7,3 @@ * License: MIT

!function(global,factory){"object"==typeof exports&&"undefined"!=typeof module?factory(exports,require("@angular/core")):"function"==typeof define&&define.amd?define(["exports","@angular/core"],factory):factory((global.ng=global.ng||{},global.ng.upgrade=global.ng.upgrade||{},global.ng.upgrade.static=global.ng.upgrade.static||{}),global.ng.core)}(this,function(exports,_angular_core){"use strict";/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -26,3 +26,3 @@ * License: MIT

*/
function downgradeInjectable(token){var factory=function(i){return i.get(token)};return factory.$inject=[INJECTOR_KEY],factory}function getOrCall(property){return isFunction(property)?property():property}function isMap(value){return value&&!Array.isArray(value)&&"object"==typeof value}function notSupported(name,feature){throw new Error("Upgraded directive '"+name+"' contains unsupported feature: '"+feature+"'.")}function setTempInjectorRef(injector){tempInjectorRef=injector}function injectorFactory(){var injector=tempInjectorRef;return tempInjectorRef=null,injector}function rootScopeFactory(i){return i.get("$rootScope")}function compileFactory(i){return i.get("$compile")}function parseFactory(i){return i.get("$parse")}var angular={bootstrap:noNg,module:noNg,element:noNg,version:noNg,resumeBootstrap:noNg,getTestability:noNg};try{window.hasOwnProperty("angular")&&(angular=window.angular)}catch(e){}var _matches,tempInjectorRef,bootstrap=function(e,modules,config){return angular.bootstrap(e,modules,config)},module$1=function(prefix,dependencies){return angular.module(prefix,dependencies)},element=function(e){return angular.element(e)},$COMPILE="$compile",$CONTROLLER="$controller",$DELEGATE="$delegate",$HTTP_BACKEND="$httpBackend",$INJECTOR="$injector",$INTERVAL="$interval",$PARSE="$parse",$PROVIDE="$provide",$SCOPE="$scope",$TEMPLATE_CACHE="$templateCache",$$TESTABILITY="$$testability",INJECTOR_KEY="$$angularInjector",REQUIRE_INJECTOR="?^^"+INJECTOR_KEY,REQUIRE_NG_MODEL="?ngModel",UPGRADE_MODULE_NAME="$$UpgradeModule",PropertyBinding=function(){function PropertyBinding(prop,attr){this.prop=prop,this.attr=attr,this.parseBinding()}return PropertyBinding.prototype.parseBinding=function(){this.bracketAttr="["+this.attr+"]",this.parenAttr="("+this.attr+")",this.bracketParenAttr="[("+this.attr+")]";var capitalAttr=this.attr.charAt(0).toUpperCase()+this.attr.substr(1);this.onAttr="on"+capitalAttr,this.bindAttr="bind"+capitalAttr,this.bindonAttr="bindon"+capitalAttr},PropertyBinding}(),DIRECTIVE_PREFIX_REGEXP=/^(?:x|data)[:\-_]/i,DIRECTIVE_SPECIAL_CHARS_REGEXP=/[:\-_]+(.)/g,INITIAL_VALUE={__UNINITIALIZED__:!0},DowngradeComponentAdapter=function(){function DowngradeComponentAdapter(id,element,attrs,scope,ngModel,parentInjector,$injector,$compile,$parse,componentFactory){this.id=id,this.element=element,this.attrs=attrs,this.scope=scope,this.ngModel=ngModel,this.parentInjector=parentInjector,this.$injector=$injector,this.$compile=$compile,this.$parse=$parse,this.componentFactory=componentFactory,this.inputChangeCount=0,this.inputChanges=null,this.componentRef=null,this.component=null,this.changeDetector=null,this.element[0].id=id,this.componentScope=scope.$new()}return DowngradeComponentAdapter.prototype.compileContents=function(){var _this=this,compiledProjectableNodes=[],projectableNodes=this.groupProjectableNodes(),linkFns=projectableNodes.map(function(nodes){return _this.$compile(nodes)});return this.element.empty(),linkFns.forEach(function(linkFn){linkFn(_this.scope,function(clone){compiledProjectableNodes.push(clone),_this.element.append(clone)})}),compiledProjectableNodes},DowngradeComponentAdapter.prototype.createComponent=function(projectableNodes){var childInjector=_angular_core.ReflectiveInjector.resolveAndCreate([{provide:$SCOPE,useValue:this.componentScope}],this.parentInjector);this.componentRef=this.componentFactory.create(childInjector,projectableNodes,this.element[0]),this.changeDetector=this.componentRef.changeDetectorRef,this.component=this.componentRef.instance,hookupNgModel(this.ngModel,this.component)},DowngradeComponentAdapter.prototype.setupInputs=function(){for(var _this=this,attrs=this.attrs,inputs=this.componentFactory.inputs||[],_loop_1=function(i){var input=new PropertyBinding(inputs[i].propName,inputs[i].templateName),expr=null;if(attrs.hasOwnProperty(input.attr)){var observeFn_1=function(prop){var prevValue=INITIAL_VALUE;return function(currValue){strictEquals(prevValue,currValue)||(prevValue===INITIAL_VALUE&&(prevValue=currValue),_this.updateInput(prop,prevValue,currValue),prevValue=currValue)}}(input.prop);attrs.$observe(input.attr,observeFn_1);var unwatch_1=this_1.componentScope.$watch(function(){unwatch_1(""),unwatch_1=null,observeFn_1(attrs[input.attr])})}else attrs.hasOwnProperty(input.bindAttr)?expr=attrs[input.bindAttr]:attrs.hasOwnProperty(input.bracketAttr)?expr=attrs[input.bracketAttr]:attrs.hasOwnProperty(input.bindonAttr)?expr=attrs[input.bindonAttr]:attrs.hasOwnProperty(input.bracketParenAttr)&&(expr=attrs[input.bracketParenAttr]);if(null!=expr){var watchFn=function(prop){return function(currValue,prevValue){return _this.updateInput(prop,prevValue,currValue)}}(input.prop);this_1.componentScope.$watch(expr,watchFn)}},this_1=this,i=0;i<inputs.length;i++)_loop_1(i);var prototype=this.componentFactory.componentType.prototype;prototype&&prototype.ngOnChanges&&(this.inputChanges={},this.componentScope.$watch(function(){return _this.inputChangeCount},function(){var inputChanges=_this.inputChanges;_this.inputChanges={},_this.component.ngOnChanges(inputChanges)})),this.componentScope.$watch(function(){return _this.changeDetector&&_this.changeDetector.detectChanges()})},DowngradeComponentAdapter.prototype.setupOutputs=function(){for(var _this=this,attrs=this.attrs,outputs=this.componentFactory.outputs||[],j=0;j<outputs.length;j++){var output=new PropertyBinding(outputs[j].propName,outputs[j].templateName),expr=null,assignExpr=!1,bindonAttr=output.bindonAttr?output.bindonAttr.substring(0,output.bindonAttr.length-6):null,bracketParenAttr=output.bracketParenAttr?"[("+output.bracketParenAttr.substring(2,output.bracketParenAttr.length-8)+")]":null;if(attrs.hasOwnProperty(output.onAttr)?expr=attrs[output.onAttr]:attrs.hasOwnProperty(output.parenAttr)?expr=attrs[output.parenAttr]:attrs.hasOwnProperty(bindonAttr)?(expr=attrs[bindonAttr],assignExpr=!0):attrs.hasOwnProperty(bracketParenAttr)&&(expr=attrs[bracketParenAttr],assignExpr=!0),null!=expr&&null!=assignExpr){var getter=this.$parse(expr),setter=getter.assign;if(assignExpr&&!setter)throw new Error("Expression '"+expr+"' is not assignable!");var emitter=this.component[output.prop];if(!emitter)throw new Error("Missing emitter '"+output.prop+"' on component '"+getComponentName(this.componentFactory.componentType)+"'!");emitter.subscribe({next:assignExpr?function(setter){return function(v){return setter(_this.scope,v)}}(setter):function(getter){return function(v){return getter(_this.scope,{$event:v})}}(getter)})}}},DowngradeComponentAdapter.prototype.registerCleanup=function(){var _this=this;this.element.bind("$destroy",function(){_this.componentScope.$destroy(),_this.componentRef.destroy()})},DowngradeComponentAdapter.prototype.getInjector=function(){return this.componentRef&&this.componentRef.injector},DowngradeComponentAdapter.prototype.updateInput=function(prop,prevValue,currValue){this.inputChanges&&(this.inputChangeCount++,this.inputChanges[prop]=new _angular_core.SimpleChange(prevValue,currValue,prevValue===currValue)),this.component[prop]=currValue},DowngradeComponentAdapter.prototype.groupProjectableNodes=function(){var ngContentSelectors=this.componentFactory.ngContentSelectors;return groupNodesBySelector(ngContentSelectors,this.element.contents())},DowngradeComponentAdapter}(),downgradeCount=0,ParentInjectorPromise=function(){function ParentInjectorPromise(element){this.element=element,this.injectorKey=controllerKey(INJECTOR_KEY),this.callbacks=[],element.data(this.injectorKey,this)}return ParentInjectorPromise.prototype.then=function(callback){this.injector?callback(this.injector):this.callbacks.push(callback)},ParentInjectorPromise.prototype.resolve=function(injector){this.injector=injector,this.element.data(this.injectorKey,injector),this.element=null,this.callbacks.forEach(function(callback){return callback(injector)}),this.callbacks.length=0},ParentInjectorPromise}(),VERSION=new _angular_core.Version("4.3.0-rc.0"),REQUIRE_PREFIX_RE=/^(\^\^?)?(\?)?(\^\^?)?/,UpgradeHelper=function(){function UpgradeHelper(injector,name,elementRef,directive){this.injector=injector,this.name=name,this.$injector=injector.get($INJECTOR),this.$compile=this.$injector.get($COMPILE),this.$controller=this.$injector.get($CONTROLLER),this.element=elementRef.nativeElement,this.$element=element(this.element),this.directive=directive||UpgradeHelper.getDirective(this.$injector,name)}return UpgradeHelper.getDirective=function($injector,name){var directives=$injector.get(name+"Directive");if(directives.length>1)throw new Error("Only support single directive definition for: "+name);var directive=directives[0];return directive.compile&&!directive.link&&notSupported(name,"compile"),directive.replace&&notSupported(name,"replace"),directive.terminal&&notSupported(name,"terminal"),directive},UpgradeHelper.getTemplate=function($injector,directive,fetchRemoteTemplate){if(void 0===fetchRemoteTemplate&&(fetchRemoteTemplate=!1),void 0!==directive.template)return getOrCall(directive.template);if(directive.templateUrl){var $templateCache_1=$injector.get($TEMPLATE_CACHE),url_1=getOrCall(directive.templateUrl),template=$templateCache_1.get(url_1);if(void 0!==template)return template;if(!fetchRemoteTemplate)throw new Error("loading directive templates asynchronously is not supported");return new Promise(function(resolve,reject){var $httpBackend=$injector.get($HTTP_BACKEND);$httpBackend("GET",url_1,null,function(status,response){200===status?resolve($templateCache_1.put(url_1,response)):reject("GET component template from '"+url_1+"' returned '"+status+": "+response+"'")})})}throw new Error("Directive '"+directive.name+"' is not a component, it is missing template.")},UpgradeHelper.prototype.buildController=function(controllerType,$scope){var locals={$scope:$scope,$element:this.$element},controller=this.$controller(controllerType,locals,null,this.directive.controllerAs);return this.$element.data(controllerKey(this.directive.name),controller),controller},UpgradeHelper.prototype.compileTemplate=function(template){return void 0===template&&(template=UpgradeHelper.getTemplate(this.$injector,this.directive)),this.compileHtml(template)},UpgradeHelper.prototype.prepareTransclusion=function(){var _this=this,transclude=this.directive.transclude,contentChildNodes=this.extractChildNodes(),$template=contentChildNodes,attachChildrenFn=function(scope,cloneAttach){return cloneAttach($template,scope)};if(transclude){var slots_1=Object.create(null);if("object"==typeof transclude){$template=[];var slotMap_1=Object.create(null),filledSlots_1=Object.create(null);Object.keys(transclude).forEach(function(slotName){var selector=transclude[slotName],optional="?"===selector.charAt(0);selector=optional?selector.substring(1):selector,slotMap_1[selector]=slotName,slots_1[slotName]=null,filledSlots_1[slotName]=optional}),contentChildNodes.forEach(function(node){var slotName=slotMap_1[directiveNormalize(node.nodeName.toLowerCase())];slotName?(filledSlots_1[slotName]=!0,slots_1[slotName]=slots_1[slotName]||[],slots_1[slotName].push(node)):$template.push(node)}),Object.keys(filledSlots_1).forEach(function(slotName){if(!filledSlots_1[slotName])throw new Error("Required transclusion slot '"+slotName+"' on directive: "+_this.name)}),Object.keys(slots_1).filter(function(slotName){return slots_1[slotName]}).forEach(function(slotName){var nodes=slots_1[slotName];slots_1[slotName]=function(scope,cloneAttach){return cloneAttach(nodes,scope)}})}attachChildrenFn.$$slots=slots_1,$template.forEach(function(node){node.nodeType!==Node.TEXT_NODE||node.nodeValue||(node.nodeValue="‌")})}return attachChildrenFn},UpgradeHelper.prototype.resolveAndBindRequiredControllers=function(controllerInstance){var directiveRequire=this.getDirectiveRequire(),requiredControllers=this.resolveRequire(directiveRequire);if(controllerInstance&&this.directive.bindToController&&isMap(directiveRequire)){var requiredControllersMap_1=requiredControllers;Object.keys(requiredControllersMap_1).forEach(function(key){controllerInstance[key]=requiredControllersMap_1[key]})}return requiredControllers},UpgradeHelper.prototype.compileHtml=function(html){return this.element.innerHTML=html,this.$compile(this.element.childNodes)},UpgradeHelper.prototype.extractChildNodes=function(){for(var childNode,childNodes=[];childNode=this.element.firstChild;)this.element.removeChild(childNode),childNodes.push(childNode);return childNodes},UpgradeHelper.prototype.getDirectiveRequire=function(){var require=this.directive.require||this.directive.controller&&this.directive.name;return isMap(require)&&Object.keys(require).forEach(function(key){var value=require[key],match=value.match(REQUIRE_PREFIX_RE),name=value.substring(match[0].length);name||(require[key]=match[0]+key)}),require},UpgradeHelper.prototype.resolveRequire=function(require,controllerInstance){var _this=this;if(require){if(Array.isArray(require))return require.map(function(req){return _this.resolveRequire(req)});if("object"==typeof require){var value_1={};return Object.keys(require).forEach(function(key){return value_1[key]=_this.resolveRequire(require[key])}),value_1}if("string"==typeof require){var match=require.match(REQUIRE_PREFIX_RE),inheritType=match[1]||match[3],name_1=require.substring(match[0].length),isOptional=!!match[2],searchParents=!!inheritType,startOnParent="^^"===inheritType,ctrlKey=controllerKey(name_1),elem=startOnParent?this.$element.parent():this.$element,value=searchParents?elem.inheritedData(ctrlKey):elem.data(ctrlKey);if(!value&&!isOptional)throw new Error("Unable to find required '"+require+"' in upgraded directive '"+this.name+"'.");return value}throw new Error("Unrecognized 'require' syntax on upgraded directive '"+this.name+"': "+require)}return null},UpgradeHelper}(),NOT_SUPPORTED="NOT_SUPPORTED",INITIAL_VALUE$1={__UNINITIALIZED__:!0},Bindings=function(){function Bindings(){this.twoWayBoundProperties=[],this.twoWayBoundLastValues=[],this.expressionBoundProperties=[],this.propertyToOutputMap={}}return Bindings}(),UpgradeComponent=function(){function UpgradeComponent(name,elementRef,injector){this.name=name,this.elementRef=elementRef,this.injector=injector,this.helper=new UpgradeHelper(injector,name,elementRef),this.$injector=this.helper.$injector,this.element=this.helper.element,this.$element=this.helper.$element,this.directive=this.helper.directive,this.bindings=this.initializeBindings(this.directive);var $parentScope=injector.get($SCOPE);this.$componentScope=$parentScope.$new(!!this.directive.scope),this.initializeOutputs()}return UpgradeComponent.prototype.ngOnInit=function(){var _this=this,attachChildNodes=this.helper.prepareTransclusion(),linkFn=this.helper.compileTemplate(),controllerType=this.directive.controller,bindToController=this.directive.bindToController;if(controllerType)this.controllerInstance=this.helper.buildController(controllerType,this.$componentScope);else if(bindToController)throw new Error("Upgraded directive '"+this.directive.name+"' specifies 'bindToController' but no controller.");this.bindingDestination=bindToController?this.controllerInstance:this.$componentScope,this.bindOutputs();var requiredControllers=this.helper.resolveAndBindRequiredControllers(this.controllerInstance);if(this.pendingChanges&&(this.forwardChanges(this.pendingChanges),this.pendingChanges=null),this.controllerInstance&&isFunction(this.controllerInstance.$onInit)&&this.controllerInstance.$onInit(),this.controllerInstance&&isFunction(this.controllerInstance.$doCheck)){var callDoCheck=function(){return _this.controllerInstance.$doCheck()};this.unregisterDoCheckWatcher=this.$componentScope.$parent.$watch(callDoCheck),callDoCheck()}var link=this.directive.link,preLink="object"==typeof link&&link.pre,postLink="object"==typeof link?link.post:link,attrs=NOT_SUPPORTED,transcludeFn=NOT_SUPPORTED;preLink&&preLink(this.$componentScope,this.$element,attrs,requiredControllers,transcludeFn),linkFn(this.$componentScope,null,{parentBoundTranscludeFn:attachChildNodes}),postLink&&postLink(this.$componentScope,this.$element,attrs,requiredControllers,transcludeFn),this.controllerInstance&&isFunction(this.controllerInstance.$postLink)&&this.controllerInstance.$postLink()},UpgradeComponent.prototype.ngOnChanges=function(changes){this.bindingDestination?this.forwardChanges(changes):this.pendingChanges=changes},UpgradeComponent.prototype.ngDoCheck=function(){var _this=this,twoWayBoundProperties=this.bindings.twoWayBoundProperties,twoWayBoundLastValues=this.bindings.twoWayBoundLastValues,propertyToOutputMap=this.bindings.propertyToOutputMap;twoWayBoundProperties.forEach(function(propName,idx){var newValue=_this.bindingDestination[propName],oldValue=twoWayBoundLastValues[idx];if(!_angular_core.ɵlooseIdentical(newValue,oldValue)){var outputName=propertyToOutputMap[propName],eventEmitter=_this[outputName];eventEmitter.emit(newValue),twoWayBoundLastValues[idx]=newValue}})},UpgradeComponent.prototype.ngOnDestroy=function(){isFunction(this.unregisterDoCheckWatcher)&&this.unregisterDoCheckWatcher(),this.controllerInstance&&isFunction(this.controllerInstance.$onDestroy)&&this.controllerInstance.$onDestroy(),this.$componentScope.$destroy()},UpgradeComponent.prototype.initializeBindings=function(directive){var _this=this,btcIsObject="object"==typeof directive.bindToController;if(btcIsObject&&Object.keys(directive.scope).length)throw new Error("Binding definitions on scope and controller at the same time is not supported.");var context=btcIsObject?directive.bindToController:directive.scope,bindings=new Bindings;return"object"==typeof context&&Object.keys(context).forEach(function(propName){var definition=context[propName],bindingType=definition.charAt(0);switch(bindingType){case"@":case"<":break;case"=":bindings.twoWayBoundProperties.push(propName),bindings.twoWayBoundLastValues.push(INITIAL_VALUE$1),bindings.propertyToOutputMap[propName]=propName+"Change";break;case"&":bindings.expressionBoundProperties.push(propName),bindings.propertyToOutputMap[propName]=propName;break;default:var json=JSON.stringify(context);throw new Error("Unexpected mapping '"+bindingType+"' in '"+json+"' in '"+_this.name+"' directive.")}}),bindings},UpgradeComponent.prototype.initializeOutputs=function(){var _this=this;this.bindings.twoWayBoundProperties.concat(this.bindings.expressionBoundProperties).forEach(function(propName){var outputName=_this.bindings.propertyToOutputMap[propName];_this[outputName]=new _angular_core.EventEmitter})},UpgradeComponent.prototype.bindOutputs=function(){var _this=this;this.bindings.expressionBoundProperties.forEach(function(propName){var outputName=_this.bindings.propertyToOutputMap[propName],emitter=_this[outputName];_this.bindingDestination[propName]=function(value){return emitter.emit(value)}})},UpgradeComponent.prototype.forwardChanges=function(changes){var _this=this;Object.keys(changes).forEach(function(propName){return _this.bindingDestination[propName]=changes[propName].currentValue}),isFunction(this.bindingDestination.$onChanges)&&this.bindingDestination.$onChanges(changes)},UpgradeComponent}(),angular1Providers=[{provide:"$injector",useFactory:injectorFactory},{provide:"$rootScope",useFactory:rootScopeFactory,deps:["$injector"]},{provide:"$compile",useFactory:compileFactory,deps:["$injector"]},{provide:"$parse",useFactory:parseFactory,deps:["$injector"]}],UpgradeModule=function(){function UpgradeModule(injector,ngZone){this.ngZone=ngZone,this.injector=new NgAdapterInjector(injector)}return UpgradeModule.prototype.bootstrap=function(element$$1,modules,config){var _this=this;void 0===modules&&(modules=[]);var INIT_MODULE_NAME=UPGRADE_MODULE_NAME+".init",upgradeModule=(module$1(INIT_MODULE_NAME,[]).value(INJECTOR_KEY,this.injector).config([$PROVIDE,$INJECTOR,function($provide,$injector){$injector.has($$TESTABILITY)&&$provide.decorator($$TESTABILITY,[$DELEGATE,function(testabilityDelegate){var originalWhenStable=testabilityDelegate.whenStable,injector=_this.injector,newWhenStable=function(callback){originalWhenStable.call(testabilityDelegate,function(){var ng2Testability=injector.get(_angular_core.Testability);ng2Testability.isStable()?callback():ng2Testability.whenStable(newWhenStable.bind(testabilityDelegate,callback))})};return testabilityDelegate.whenStable=newWhenStable,testabilityDelegate}]),$injector.has($INTERVAL)&&$provide.decorator($INTERVAL,[$DELEGATE,function(intervalDelegate){var wrappedInterval=function(fn,delay,count,invokeApply){for(var pass=[],_i=4;_i<arguments.length;_i++)pass[_i-4]=arguments[_i];return _this.ngZone.runOutsideAngular(function(){return intervalDelegate.apply(void 0,[function(){for(var args=[],_i=0;_i<arguments.length;_i++)args[_i]=arguments[_i];setTimeout(function(){_this.ngZone.run(function(){return fn.apply(void 0,args)})})},delay,count,invokeApply].concat(pass))})};return wrappedInterval.cancel=intervalDelegate.cancel,wrappedInterval}])}]).run([$INJECTOR,function($injector){_this.$injector=$injector,setTempInjectorRef($injector),_this.injector.get($INJECTOR),element(element$$1).data(controllerKey(INJECTOR_KEY),_this.injector),setTimeout(function(){var $rootScope=$injector.get("$rootScope"),subscription=_this.ngZone.onMicrotaskEmpty.subscribe(function(){return $rootScope.$digest()});$rootScope.$on("$destroy",function(){subscription.unsubscribe()})},0)}]),module$1(UPGRADE_MODULE_NAME,[INIT_MODULE_NAME].concat(modules))),windowAngular=window.angular;if(windowAngular.resumeBootstrap=void 0,this.ngZone.run(function(){bootstrap(element$$1,[upgradeModule.name],config)}),windowAngular.resumeBootstrap){var originalResumeBootstrap_1=windowAngular.resumeBootstrap,ngZone_1=this.ngZone;windowAngular.resumeBootstrap=function(){var _this=this,args=arguments;windowAngular.resumeBootstrap=originalResumeBootstrap_1,ngZone_1.run(function(){windowAngular.resumeBootstrap.apply(_this,args)})}}},UpgradeModule}();UpgradeModule.decorators=[{type:_angular_core.NgModule,args:[{providers:[angular1Providers]}]}],UpgradeModule.ctorParameters=function(){return[{type:_angular_core.Injector},{type:_angular_core.NgZone}]};var NgAdapterInjector=function(){function NgAdapterInjector(modInjector){this.modInjector=modInjector}return NgAdapterInjector.prototype.get=function(token,notFoundValue){return notFoundValue===_angular_core.ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR?notFoundValue:this.modInjector.get(token,notFoundValue)},NgAdapterInjector}();exports.ɵe=angular1Providers,exports.ɵc=compileFactory,exports.ɵa=injectorFactory,exports.ɵd=parseFactory,exports.ɵb=rootScopeFactory,exports.getAngularLib=getAngularLib,exports.setAngularLib=setAngularLib,exports.downgradeComponent=downgradeComponent,exports.downgradeInjectable=downgradeInjectable,exports.VERSION=VERSION,exports.UpgradeComponent=UpgradeComponent,exports.UpgradeModule=UpgradeModule,Object.defineProperty(exports,"__esModule",{value:!0})});
function downgradeInjectable(token){var factory=function(i){return i.get(token)};return factory.$inject=[INJECTOR_KEY],factory}function getOrCall(property){return isFunction(property)?property():property}function isMap(value){return value&&!Array.isArray(value)&&"object"==typeof value}function notSupported(name,feature){throw new Error("Upgraded directive '"+name+"' contains unsupported feature: '"+feature+"'.")}function setTempInjectorRef(injector){tempInjectorRef=injector}function injectorFactory(){var injector=tempInjectorRef;return tempInjectorRef=null,injector}function rootScopeFactory(i){return i.get("$rootScope")}function compileFactory(i){return i.get("$compile")}function parseFactory(i){return i.get("$parse")}var angular={bootstrap:noNg,module:noNg,element:noNg,version:noNg,resumeBootstrap:noNg,getTestability:noNg};try{window.hasOwnProperty("angular")&&(angular=window.angular)}catch(e){}var _matches,tempInjectorRef,bootstrap=function(e,modules,config){return angular.bootstrap(e,modules,config)},module$1=function(prefix,dependencies){return angular.module(prefix,dependencies)},element=function(e){return angular.element(e)},$COMPILE="$compile",$CONTROLLER="$controller",$DELEGATE="$delegate",$HTTP_BACKEND="$httpBackend",$INJECTOR="$injector",$INTERVAL="$interval",$PARSE="$parse",$PROVIDE="$provide",$SCOPE="$scope",$TEMPLATE_CACHE="$templateCache",$$TESTABILITY="$$testability",INJECTOR_KEY="$$angularInjector",REQUIRE_INJECTOR="?^^"+INJECTOR_KEY,REQUIRE_NG_MODEL="?ngModel",UPGRADE_MODULE_NAME="$$UpgradeModule",PropertyBinding=function(){function PropertyBinding(prop,attr){this.prop=prop,this.attr=attr,this.parseBinding()}return PropertyBinding.prototype.parseBinding=function(){this.bracketAttr="["+this.attr+"]",this.parenAttr="("+this.attr+")",this.bracketParenAttr="[("+this.attr+")]";var capitalAttr=this.attr.charAt(0).toUpperCase()+this.attr.substr(1);this.onAttr="on"+capitalAttr,this.bindAttr="bind"+capitalAttr,this.bindonAttr="bindon"+capitalAttr},PropertyBinding}(),DIRECTIVE_PREFIX_REGEXP=/^(?:x|data)[:\-_]/i,DIRECTIVE_SPECIAL_CHARS_REGEXP=/[:\-_]+(.)/g,INITIAL_VALUE={__UNINITIALIZED__:!0},DowngradeComponentAdapter=function(){function DowngradeComponentAdapter(id,element,attrs,scope,ngModel,parentInjector,$injector,$compile,$parse,componentFactory){this.id=id,this.element=element,this.attrs=attrs,this.scope=scope,this.ngModel=ngModel,this.parentInjector=parentInjector,this.$injector=$injector,this.$compile=$compile,this.$parse=$parse,this.componentFactory=componentFactory,this.inputChangeCount=0,this.inputChanges=null,this.componentRef=null,this.component=null,this.changeDetector=null,this.element[0].id=id,this.componentScope=scope.$new()}return DowngradeComponentAdapter.prototype.compileContents=function(){var _this=this,compiledProjectableNodes=[],projectableNodes=this.groupProjectableNodes(),linkFns=projectableNodes.map(function(nodes){return _this.$compile(nodes)});return this.element.empty(),linkFns.forEach(function(linkFn){linkFn(_this.scope,function(clone){compiledProjectableNodes.push(clone),_this.element.append(clone)})}),compiledProjectableNodes},DowngradeComponentAdapter.prototype.createComponent=function(projectableNodes){var childInjector=_angular_core.ReflectiveInjector.resolveAndCreate([{provide:$SCOPE,useValue:this.componentScope}],this.parentInjector);this.componentRef=this.componentFactory.create(childInjector,projectableNodes,this.element[0]),this.changeDetector=this.componentRef.changeDetectorRef,this.component=this.componentRef.instance,hookupNgModel(this.ngModel,this.component)},DowngradeComponentAdapter.prototype.setupInputs=function(){for(var _this=this,attrs=this.attrs,inputs=this.componentFactory.inputs||[],_loop_1=function(i){var input=new PropertyBinding(inputs[i].propName,inputs[i].templateName),expr=null;if(attrs.hasOwnProperty(input.attr)){var observeFn_1=function(prop){var prevValue=INITIAL_VALUE;return function(currValue){strictEquals(prevValue,currValue)||(prevValue===INITIAL_VALUE&&(prevValue=currValue),_this.updateInput(prop,prevValue,currValue),prevValue=currValue)}}(input.prop);attrs.$observe(input.attr,observeFn_1);var unwatch_1=this_1.componentScope.$watch(function(){unwatch_1(""),unwatch_1=null,observeFn_1(attrs[input.attr])})}else attrs.hasOwnProperty(input.bindAttr)?expr=attrs[input.bindAttr]:attrs.hasOwnProperty(input.bracketAttr)?expr=attrs[input.bracketAttr]:attrs.hasOwnProperty(input.bindonAttr)?expr=attrs[input.bindonAttr]:attrs.hasOwnProperty(input.bracketParenAttr)&&(expr=attrs[input.bracketParenAttr]);if(null!=expr){var watchFn=function(prop){return function(currValue,prevValue){return _this.updateInput(prop,prevValue,currValue)}}(input.prop);this_1.componentScope.$watch(expr,watchFn)}},this_1=this,i=0;i<inputs.length;i++)_loop_1(i);var prototype=this.componentFactory.componentType.prototype;prototype&&prototype.ngOnChanges&&(this.inputChanges={},this.componentScope.$watch(function(){return _this.inputChangeCount},function(){var inputChanges=_this.inputChanges;_this.inputChanges={},_this.component.ngOnChanges(inputChanges)})),this.componentScope.$watch(function(){return _this.changeDetector&&_this.changeDetector.detectChanges()})},DowngradeComponentAdapter.prototype.setupOutputs=function(){for(var _this=this,attrs=this.attrs,outputs=this.componentFactory.outputs||[],j=0;j<outputs.length;j++){var output=new PropertyBinding(outputs[j].propName,outputs[j].templateName),expr=null,assignExpr=!1,bindonAttr=output.bindonAttr?output.bindonAttr.substring(0,output.bindonAttr.length-6):null,bracketParenAttr=output.bracketParenAttr?"[("+output.bracketParenAttr.substring(2,output.bracketParenAttr.length-8)+")]":null;if(attrs.hasOwnProperty(output.onAttr)?expr=attrs[output.onAttr]:attrs.hasOwnProperty(output.parenAttr)?expr=attrs[output.parenAttr]:attrs.hasOwnProperty(bindonAttr)?(expr=attrs[bindonAttr],assignExpr=!0):attrs.hasOwnProperty(bracketParenAttr)&&(expr=attrs[bracketParenAttr],assignExpr=!0),null!=expr&&null!=assignExpr){var getter=this.$parse(expr),setter=getter.assign;if(assignExpr&&!setter)throw new Error("Expression '"+expr+"' is not assignable!");var emitter=this.component[output.prop];if(!emitter)throw new Error("Missing emitter '"+output.prop+"' on component '"+getComponentName(this.componentFactory.componentType)+"'!");emitter.subscribe({next:assignExpr?function(setter){return function(v){return setter(_this.scope,v)}}(setter):function(getter){return function(v){return getter(_this.scope,{$event:v})}}(getter)})}}},DowngradeComponentAdapter.prototype.registerCleanup=function(){var _this=this;this.element.bind("$destroy",function(){_this.componentScope.$destroy(),_this.componentRef.destroy()})},DowngradeComponentAdapter.prototype.getInjector=function(){return this.componentRef&&this.componentRef.injector},DowngradeComponentAdapter.prototype.updateInput=function(prop,prevValue,currValue){this.inputChanges&&(this.inputChangeCount++,this.inputChanges[prop]=new _angular_core.SimpleChange(prevValue,currValue,prevValue===currValue)),this.component[prop]=currValue},DowngradeComponentAdapter.prototype.groupProjectableNodes=function(){var ngContentSelectors=this.componentFactory.ngContentSelectors;return groupNodesBySelector(ngContentSelectors,this.element.contents())},DowngradeComponentAdapter}(),downgradeCount=0,ParentInjectorPromise=function(){function ParentInjectorPromise(element){this.element=element,this.injectorKey=controllerKey(INJECTOR_KEY),this.callbacks=[],element.data(this.injectorKey,this)}return ParentInjectorPromise.prototype.then=function(callback){this.injector?callback(this.injector):this.callbacks.push(callback)},ParentInjectorPromise.prototype.resolve=function(injector){this.injector=injector,this.element.data(this.injectorKey,injector),this.element=null,this.callbacks.forEach(function(callback){return callback(injector)}),this.callbacks.length=0},ParentInjectorPromise}(),VERSION=new _angular_core.Version("4.3.0"),REQUIRE_PREFIX_RE=/^(\^\^?)?(\?)?(\^\^?)?/,UpgradeHelper=function(){function UpgradeHelper(injector,name,elementRef,directive){this.injector=injector,this.name=name,this.$injector=injector.get($INJECTOR),this.$compile=this.$injector.get($COMPILE),this.$controller=this.$injector.get($CONTROLLER),this.element=elementRef.nativeElement,this.$element=element(this.element),this.directive=directive||UpgradeHelper.getDirective(this.$injector,name)}return UpgradeHelper.getDirective=function($injector,name){var directives=$injector.get(name+"Directive");if(directives.length>1)throw new Error("Only support single directive definition for: "+name);var directive=directives[0];return directive.compile&&!directive.link&&notSupported(name,"compile"),directive.replace&&notSupported(name,"replace"),directive.terminal&&notSupported(name,"terminal"),directive},UpgradeHelper.getTemplate=function($injector,directive,fetchRemoteTemplate){if(void 0===fetchRemoteTemplate&&(fetchRemoteTemplate=!1),void 0!==directive.template)return getOrCall(directive.template);if(directive.templateUrl){var $templateCache_1=$injector.get($TEMPLATE_CACHE),url_1=getOrCall(directive.templateUrl),template=$templateCache_1.get(url_1);if(void 0!==template)return template;if(!fetchRemoteTemplate)throw new Error("loading directive templates asynchronously is not supported");return new Promise(function(resolve,reject){var $httpBackend=$injector.get($HTTP_BACKEND);$httpBackend("GET",url_1,null,function(status,response){200===status?resolve($templateCache_1.put(url_1,response)):reject("GET component template from '"+url_1+"' returned '"+status+": "+response+"'")})})}throw new Error("Directive '"+directive.name+"' is not a component, it is missing template.")},UpgradeHelper.prototype.buildController=function(controllerType,$scope){var locals={$scope:$scope,$element:this.$element},controller=this.$controller(controllerType,locals,null,this.directive.controllerAs);return this.$element.data(controllerKey(this.directive.name),controller),controller},UpgradeHelper.prototype.compileTemplate=function(template){return void 0===template&&(template=UpgradeHelper.getTemplate(this.$injector,this.directive)),this.compileHtml(template)},UpgradeHelper.prototype.prepareTransclusion=function(){var _this=this,transclude=this.directive.transclude,contentChildNodes=this.extractChildNodes(),$template=contentChildNodes,attachChildrenFn=function(scope,cloneAttach){return cloneAttach($template,scope)};if(transclude){var slots_1=Object.create(null);if("object"==typeof transclude){$template=[];var slotMap_1=Object.create(null),filledSlots_1=Object.create(null);Object.keys(transclude).forEach(function(slotName){var selector=transclude[slotName],optional="?"===selector.charAt(0);selector=optional?selector.substring(1):selector,slotMap_1[selector]=slotName,slots_1[slotName]=null,filledSlots_1[slotName]=optional}),contentChildNodes.forEach(function(node){var slotName=slotMap_1[directiveNormalize(node.nodeName.toLowerCase())];slotName?(filledSlots_1[slotName]=!0,slots_1[slotName]=slots_1[slotName]||[],slots_1[slotName].push(node)):$template.push(node)}),Object.keys(filledSlots_1).forEach(function(slotName){if(!filledSlots_1[slotName])throw new Error("Required transclusion slot '"+slotName+"' on directive: "+_this.name)}),Object.keys(slots_1).filter(function(slotName){return slots_1[slotName]}).forEach(function(slotName){var nodes=slots_1[slotName];slots_1[slotName]=function(scope,cloneAttach){return cloneAttach(nodes,scope)}})}attachChildrenFn.$$slots=slots_1,$template.forEach(function(node){node.nodeType!==Node.TEXT_NODE||node.nodeValue||(node.nodeValue="‌")})}return attachChildrenFn},UpgradeHelper.prototype.resolveAndBindRequiredControllers=function(controllerInstance){var directiveRequire=this.getDirectiveRequire(),requiredControllers=this.resolveRequire(directiveRequire);if(controllerInstance&&this.directive.bindToController&&isMap(directiveRequire)){var requiredControllersMap_1=requiredControllers;Object.keys(requiredControllersMap_1).forEach(function(key){controllerInstance[key]=requiredControllersMap_1[key]})}return requiredControllers},UpgradeHelper.prototype.compileHtml=function(html){return this.element.innerHTML=html,this.$compile(this.element.childNodes)},UpgradeHelper.prototype.extractChildNodes=function(){for(var childNode,childNodes=[];childNode=this.element.firstChild;)this.element.removeChild(childNode),childNodes.push(childNode);return childNodes},UpgradeHelper.prototype.getDirectiveRequire=function(){var require=this.directive.require||this.directive.controller&&this.directive.name;return isMap(require)&&Object.keys(require).forEach(function(key){var value=require[key],match=value.match(REQUIRE_PREFIX_RE),name=value.substring(match[0].length);name||(require[key]=match[0]+key)}),require},UpgradeHelper.prototype.resolveRequire=function(require,controllerInstance){var _this=this;if(require){if(Array.isArray(require))return require.map(function(req){return _this.resolveRequire(req)});if("object"==typeof require){var value_1={};return Object.keys(require).forEach(function(key){return value_1[key]=_this.resolveRequire(require[key])}),value_1}if("string"==typeof require){var match=require.match(REQUIRE_PREFIX_RE),inheritType=match[1]||match[3],name_1=require.substring(match[0].length),isOptional=!!match[2],searchParents=!!inheritType,startOnParent="^^"===inheritType,ctrlKey=controllerKey(name_1),elem=startOnParent?this.$element.parent():this.$element,value=searchParents?elem.inheritedData(ctrlKey):elem.data(ctrlKey);if(!value&&!isOptional)throw new Error("Unable to find required '"+require+"' in upgraded directive '"+this.name+"'.");return value}throw new Error("Unrecognized 'require' syntax on upgraded directive '"+this.name+"': "+require)}return null},UpgradeHelper}(),NOT_SUPPORTED="NOT_SUPPORTED",INITIAL_VALUE$1={__UNINITIALIZED__:!0},Bindings=function(){function Bindings(){this.twoWayBoundProperties=[],this.twoWayBoundLastValues=[],this.expressionBoundProperties=[],this.propertyToOutputMap={}}return Bindings}(),UpgradeComponent=function(){function UpgradeComponent(name,elementRef,injector){this.name=name,this.elementRef=elementRef,this.injector=injector,this.helper=new UpgradeHelper(injector,name,elementRef),this.$injector=this.helper.$injector,this.element=this.helper.element,this.$element=this.helper.$element,this.directive=this.helper.directive,this.bindings=this.initializeBindings(this.directive);var $parentScope=injector.get($SCOPE);this.$componentScope=$parentScope.$new(!!this.directive.scope),this.initializeOutputs()}return UpgradeComponent.prototype.ngOnInit=function(){var _this=this,attachChildNodes=this.helper.prepareTransclusion(),linkFn=this.helper.compileTemplate(),controllerType=this.directive.controller,bindToController=this.directive.bindToController;if(controllerType)this.controllerInstance=this.helper.buildController(controllerType,this.$componentScope);else if(bindToController)throw new Error("Upgraded directive '"+this.directive.name+"' specifies 'bindToController' but no controller.");this.bindingDestination=bindToController?this.controllerInstance:this.$componentScope,this.bindOutputs();var requiredControllers=this.helper.resolveAndBindRequiredControllers(this.controllerInstance);if(this.pendingChanges&&(this.forwardChanges(this.pendingChanges),this.pendingChanges=null),this.controllerInstance&&isFunction(this.controllerInstance.$onInit)&&this.controllerInstance.$onInit(),this.controllerInstance&&isFunction(this.controllerInstance.$doCheck)){var callDoCheck=function(){return _this.controllerInstance.$doCheck()};this.unregisterDoCheckWatcher=this.$componentScope.$parent.$watch(callDoCheck),callDoCheck()}var link=this.directive.link,preLink="object"==typeof link&&link.pre,postLink="object"==typeof link?link.post:link,attrs=NOT_SUPPORTED,transcludeFn=NOT_SUPPORTED;preLink&&preLink(this.$componentScope,this.$element,attrs,requiredControllers,transcludeFn),linkFn(this.$componentScope,null,{parentBoundTranscludeFn:attachChildNodes}),postLink&&postLink(this.$componentScope,this.$element,attrs,requiredControllers,transcludeFn),this.controllerInstance&&isFunction(this.controllerInstance.$postLink)&&this.controllerInstance.$postLink()},UpgradeComponent.prototype.ngOnChanges=function(changes){this.bindingDestination?this.forwardChanges(changes):this.pendingChanges=changes},UpgradeComponent.prototype.ngDoCheck=function(){var _this=this,twoWayBoundProperties=this.bindings.twoWayBoundProperties,twoWayBoundLastValues=this.bindings.twoWayBoundLastValues,propertyToOutputMap=this.bindings.propertyToOutputMap;twoWayBoundProperties.forEach(function(propName,idx){var newValue=_this.bindingDestination[propName],oldValue=twoWayBoundLastValues[idx];if(!_angular_core.ɵlooseIdentical(newValue,oldValue)){var outputName=propertyToOutputMap[propName],eventEmitter=_this[outputName];eventEmitter.emit(newValue),twoWayBoundLastValues[idx]=newValue}})},UpgradeComponent.prototype.ngOnDestroy=function(){isFunction(this.unregisterDoCheckWatcher)&&this.unregisterDoCheckWatcher(),this.controllerInstance&&isFunction(this.controllerInstance.$onDestroy)&&this.controllerInstance.$onDestroy(),this.$componentScope.$destroy()},UpgradeComponent.prototype.initializeBindings=function(directive){var _this=this,btcIsObject="object"==typeof directive.bindToController;if(btcIsObject&&Object.keys(directive.scope).length)throw new Error("Binding definitions on scope and controller at the same time is not supported.");var context=btcIsObject?directive.bindToController:directive.scope,bindings=new Bindings;return"object"==typeof context&&Object.keys(context).forEach(function(propName){var definition=context[propName],bindingType=definition.charAt(0);switch(bindingType){case"@":case"<":break;case"=":bindings.twoWayBoundProperties.push(propName),bindings.twoWayBoundLastValues.push(INITIAL_VALUE$1),bindings.propertyToOutputMap[propName]=propName+"Change";break;case"&":bindings.expressionBoundProperties.push(propName),bindings.propertyToOutputMap[propName]=propName;break;default:var json=JSON.stringify(context);throw new Error("Unexpected mapping '"+bindingType+"' in '"+json+"' in '"+_this.name+"' directive.")}}),bindings},UpgradeComponent.prototype.initializeOutputs=function(){var _this=this;this.bindings.twoWayBoundProperties.concat(this.bindings.expressionBoundProperties).forEach(function(propName){var outputName=_this.bindings.propertyToOutputMap[propName];_this[outputName]=new _angular_core.EventEmitter})},UpgradeComponent.prototype.bindOutputs=function(){var _this=this;this.bindings.expressionBoundProperties.forEach(function(propName){var outputName=_this.bindings.propertyToOutputMap[propName],emitter=_this[outputName];_this.bindingDestination[propName]=function(value){return emitter.emit(value)}})},UpgradeComponent.prototype.forwardChanges=function(changes){var _this=this;Object.keys(changes).forEach(function(propName){return _this.bindingDestination[propName]=changes[propName].currentValue}),isFunction(this.bindingDestination.$onChanges)&&this.bindingDestination.$onChanges(changes)},UpgradeComponent}(),angular1Providers=[{provide:"$injector",useFactory:injectorFactory},{provide:"$rootScope",useFactory:rootScopeFactory,deps:["$injector"]},{provide:"$compile",useFactory:compileFactory,deps:["$injector"]},{provide:"$parse",useFactory:parseFactory,deps:["$injector"]}],UpgradeModule=function(){function UpgradeModule(injector,ngZone){this.ngZone=ngZone,this.injector=new NgAdapterInjector(injector)}return UpgradeModule.prototype.bootstrap=function(element$$1,modules,config){var _this=this;void 0===modules&&(modules=[]);var INIT_MODULE_NAME=UPGRADE_MODULE_NAME+".init",upgradeModule=(module$1(INIT_MODULE_NAME,[]).value(INJECTOR_KEY,this.injector).config([$PROVIDE,$INJECTOR,function($provide,$injector){$injector.has($$TESTABILITY)&&$provide.decorator($$TESTABILITY,[$DELEGATE,function(testabilityDelegate){var originalWhenStable=testabilityDelegate.whenStable,injector=_this.injector,newWhenStable=function(callback){originalWhenStable.call(testabilityDelegate,function(){var ng2Testability=injector.get(_angular_core.Testability);ng2Testability.isStable()?callback():ng2Testability.whenStable(newWhenStable.bind(testabilityDelegate,callback))})};return testabilityDelegate.whenStable=newWhenStable,testabilityDelegate}]),$injector.has($INTERVAL)&&$provide.decorator($INTERVAL,[$DELEGATE,function(intervalDelegate){var wrappedInterval=function(fn,delay,count,invokeApply){for(var pass=[],_i=4;_i<arguments.length;_i++)pass[_i-4]=arguments[_i];return _this.ngZone.runOutsideAngular(function(){return intervalDelegate.apply(void 0,[function(){for(var args=[],_i=0;_i<arguments.length;_i++)args[_i]=arguments[_i];setTimeout(function(){_this.ngZone.run(function(){return fn.apply(void 0,args)})})},delay,count,invokeApply].concat(pass))})};return wrappedInterval.cancel=intervalDelegate.cancel,wrappedInterval}])}]).run([$INJECTOR,function($injector){_this.$injector=$injector,setTempInjectorRef($injector),_this.injector.get($INJECTOR),element(element$$1).data(controllerKey(INJECTOR_KEY),_this.injector),setTimeout(function(){var $rootScope=$injector.get("$rootScope"),subscription=_this.ngZone.onMicrotaskEmpty.subscribe(function(){return $rootScope.$digest()});$rootScope.$on("$destroy",function(){subscription.unsubscribe()})},0)}]),module$1(UPGRADE_MODULE_NAME,[INIT_MODULE_NAME].concat(modules))),windowAngular=window.angular;if(windowAngular.resumeBootstrap=void 0,this.ngZone.run(function(){bootstrap(element$$1,[upgradeModule.name],config)}),windowAngular.resumeBootstrap){var originalResumeBootstrap_1=windowAngular.resumeBootstrap,ngZone_1=this.ngZone;windowAngular.resumeBootstrap=function(){var _this=this,args=arguments;windowAngular.resumeBootstrap=originalResumeBootstrap_1,ngZone_1.run(function(){windowAngular.resumeBootstrap.apply(_this,args)})}}},UpgradeModule}();UpgradeModule.decorators=[{type:_angular_core.NgModule,args:[{providers:[angular1Providers]}]}],UpgradeModule.ctorParameters=function(){return[{type:_angular_core.Injector},{type:_angular_core.NgZone}]};var NgAdapterInjector=function(){function NgAdapterInjector(modInjector){this.modInjector=modInjector}return NgAdapterInjector.prototype.get=function(token,notFoundValue){return notFoundValue===_angular_core.ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR?notFoundValue:this.modInjector.get(token,notFoundValue)},NgAdapterInjector}();exports.ɵe=angular1Providers,exports.ɵc=compileFactory,exports.ɵa=injectorFactory,exports.ɵd=parseFactory,exports.ɵb=rootScopeFactory,exports.getAngularLib=getAngularLib,exports.setAngularLib=setAngularLib,exports.downgradeComponent=downgradeComponent,exports.downgradeInjectable=downgradeInjectable,exports.VERSION=VERSION,exports.UpgradeComponent=UpgradeComponent,exports.UpgradeModule=UpgradeModule,Object.defineProperty(exports,"__esModule",{value:!0})});
//# sourceMappingURL=upgrade-static.umd.min.js.map
/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -21,3 +21,3 @@ * License: MIT

function downgradeInjectable(token){var factory=function(i){return i.get(token)};return factory.$inject=[INJECTOR_KEY],factory}function getOrCall(property){return isFunction(property)?property():property}function isMap(value){return value&&!Array.isArray(value)&&"object"==typeof value}function notSupported(name,feature){throw new Error("Upgraded directive '"+name+"' contains unsupported feature: '"+feature+"'.")}/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -33,3 +33,3 @@ * License: MIT

*/
var VERSION=new _angular_core.Version("4.3.0-rc.0"),angular={bootstrap:noNg,module:noNg,element:noNg,version:noNg,resumeBootstrap:noNg,getTestability:noNg};try{window.hasOwnProperty("angular")&&(angular=window.angular)}catch(e){}var _matches,bootstrap=function(e,modules,config){return angular.bootstrap(e,modules,config)},module$1=function(prefix,dependencies){return angular.module(prefix,dependencies)},element=function(e){return angular.element(e)},$COMPILE="$compile",$CONTROLLER="$controller",$HTTP_BACKEND="$httpBackend",$INJECTOR="$injector",$PARSE="$parse",$ROOT_SCOPE="$rootScope",$SCOPE="$scope",$TEMPLATE_CACHE="$templateCache",$$TESTABILITY="$$testability",COMPILER_KEY="$$angularCompiler",INJECTOR_KEY="$$angularInjector",NG_ZONE_KEY="$$angularNgZone",REQUIRE_INJECTOR="?^^"+INJECTOR_KEY,REQUIRE_NG_MODEL="?ngModel",PropertyBinding=function(){function PropertyBinding(prop,attr){this.prop=prop,this.attr=attr,this.parseBinding()}return PropertyBinding.prototype.parseBinding=function(){this.bracketAttr="["+this.attr+"]",this.parenAttr="("+this.attr+")",this.bracketParenAttr="[("+this.attr+")]";var capitalAttr=this.attr.charAt(0).toUpperCase()+this.attr.substr(1);this.onAttr="on"+capitalAttr,this.bindAttr="bind"+capitalAttr,this.bindonAttr="bindon"+capitalAttr},PropertyBinding}(),DIRECTIVE_PREFIX_REGEXP=/^(?:x|data)[:\-_]/i,DIRECTIVE_SPECIAL_CHARS_REGEXP=/[:\-_]+(.)/g,Deferred=function(){function Deferred(){var _this=this;this.promise=new Promise(function(res,rej){_this.resolve=res,_this.reject=rej})}return Deferred}(),INITIAL_VALUE={__UNINITIALIZED__:!0},DowngradeComponentAdapter=function(){function DowngradeComponentAdapter(id,element,attrs,scope,ngModel,parentInjector,$injector,$compile,$parse,componentFactory){this.id=id,this.element=element,this.attrs=attrs,this.scope=scope,this.ngModel=ngModel,this.parentInjector=parentInjector,this.$injector=$injector,this.$compile=$compile,this.$parse=$parse,this.componentFactory=componentFactory,this.inputChangeCount=0,this.inputChanges=null,this.componentRef=null,this.component=null,this.changeDetector=null,this.element[0].id=id,this.componentScope=scope.$new()}return DowngradeComponentAdapter.prototype.compileContents=function(){var _this=this,compiledProjectableNodes=[],projectableNodes=this.groupProjectableNodes(),linkFns=projectableNodes.map(function(nodes){return _this.$compile(nodes)});return this.element.empty(),linkFns.forEach(function(linkFn){linkFn(_this.scope,function(clone){compiledProjectableNodes.push(clone),_this.element.append(clone)})}),compiledProjectableNodes},DowngradeComponentAdapter.prototype.createComponent=function(projectableNodes){var childInjector=_angular_core.ReflectiveInjector.resolveAndCreate([{provide:$SCOPE,useValue:this.componentScope}],this.parentInjector);this.componentRef=this.componentFactory.create(childInjector,projectableNodes,this.element[0]),this.changeDetector=this.componentRef.changeDetectorRef,this.component=this.componentRef.instance,hookupNgModel(this.ngModel,this.component)},DowngradeComponentAdapter.prototype.setupInputs=function(){for(var _this=this,attrs=this.attrs,inputs=this.componentFactory.inputs||[],_loop_1=function(i){var input=new PropertyBinding(inputs[i].propName,inputs[i].templateName),expr=null;if(attrs.hasOwnProperty(input.attr)){var observeFn_1=function(prop){var prevValue=INITIAL_VALUE;return function(currValue){strictEquals(prevValue,currValue)||(prevValue===INITIAL_VALUE&&(prevValue=currValue),_this.updateInput(prop,prevValue,currValue),prevValue=currValue)}}(input.prop);attrs.$observe(input.attr,observeFn_1);var unwatch_1=this_1.componentScope.$watch(function(){unwatch_1(""),unwatch_1=null,observeFn_1(attrs[input.attr])})}else attrs.hasOwnProperty(input.bindAttr)?expr=attrs[input.bindAttr]:attrs.hasOwnProperty(input.bracketAttr)?expr=attrs[input.bracketAttr]:attrs.hasOwnProperty(input.bindonAttr)?expr=attrs[input.bindonAttr]:attrs.hasOwnProperty(input.bracketParenAttr)&&(expr=attrs[input.bracketParenAttr]);if(null!=expr){var watchFn=function(prop){return function(currValue,prevValue){return _this.updateInput(prop,prevValue,currValue)}}(input.prop);this_1.componentScope.$watch(expr,watchFn)}},this_1=this,i=0;i<inputs.length;i++)_loop_1(i);var prototype=this.componentFactory.componentType.prototype;prototype&&prototype.ngOnChanges&&(this.inputChanges={},this.componentScope.$watch(function(){return _this.inputChangeCount},function(){var inputChanges=_this.inputChanges;_this.inputChanges={},_this.component.ngOnChanges(inputChanges)})),this.componentScope.$watch(function(){return _this.changeDetector&&_this.changeDetector.detectChanges()})},DowngradeComponentAdapter.prototype.setupOutputs=function(){for(var _this=this,attrs=this.attrs,outputs=this.componentFactory.outputs||[],j=0;j<outputs.length;j++){var output=new PropertyBinding(outputs[j].propName,outputs[j].templateName),expr=null,assignExpr=!1,bindonAttr=output.bindonAttr?output.bindonAttr.substring(0,output.bindonAttr.length-6):null,bracketParenAttr=output.bracketParenAttr?"[("+output.bracketParenAttr.substring(2,output.bracketParenAttr.length-8)+")]":null;if(attrs.hasOwnProperty(output.onAttr)?expr=attrs[output.onAttr]:attrs.hasOwnProperty(output.parenAttr)?expr=attrs[output.parenAttr]:attrs.hasOwnProperty(bindonAttr)?(expr=attrs[bindonAttr],assignExpr=!0):attrs.hasOwnProperty(bracketParenAttr)&&(expr=attrs[bracketParenAttr],assignExpr=!0),null!=expr&&null!=assignExpr){var getter=this.$parse(expr),setter=getter.assign;if(assignExpr&&!setter)throw new Error("Expression '"+expr+"' is not assignable!");var emitter=this.component[output.prop];if(!emitter)throw new Error("Missing emitter '"+output.prop+"' on component '"+getComponentName(this.componentFactory.componentType)+"'!");emitter.subscribe({next:assignExpr?function(setter){return function(v){return setter(_this.scope,v)}}(setter):function(getter){return function(v){return getter(_this.scope,{$event:v})}}(getter)})}}},DowngradeComponentAdapter.prototype.registerCleanup=function(){var _this=this;this.element.bind("$destroy",function(){_this.componentScope.$destroy(),_this.componentRef.destroy()})},DowngradeComponentAdapter.prototype.getInjector=function(){return this.componentRef&&this.componentRef.injector},DowngradeComponentAdapter.prototype.updateInput=function(prop,prevValue,currValue){this.inputChanges&&(this.inputChangeCount++,this.inputChanges[prop]=new _angular_core.SimpleChange(prevValue,currValue,prevValue===currValue)),this.component[prop]=currValue},DowngradeComponentAdapter.prototype.groupProjectableNodes=function(){var ngContentSelectors=this.componentFactory.ngContentSelectors;return groupNodesBySelector(ngContentSelectors,this.element.contents())},DowngradeComponentAdapter}(),downgradeCount=0,ParentInjectorPromise$1=function(){function ParentInjectorPromise$1(element){this.element=element,this.injectorKey=controllerKey(INJECTOR_KEY),this.callbacks=[],element.data(this.injectorKey,this)}return ParentInjectorPromise$1.prototype.then=function(callback){this.injector?callback(this.injector):this.callbacks.push(callback)},ParentInjectorPromise$1.prototype.resolve=function(injector){this.injector=injector,this.element.data(this.injectorKey,injector),this.element=null,this.callbacks.forEach(function(callback){return callback(injector)}),this.callbacks.length=0},ParentInjectorPromise$1}(),REQUIRE_PREFIX_RE=/^(\^\^?)?(\?)?(\^\^?)?/,UpgradeHelper=function(){function UpgradeHelper(injector,name,elementRef,directive){this.injector=injector,this.name=name,this.$injector=injector.get($INJECTOR),this.$compile=this.$injector.get($COMPILE),this.$controller=this.$injector.get($CONTROLLER),this.element=elementRef.nativeElement,this.$element=element(this.element),this.directive=directive||UpgradeHelper.getDirective(this.$injector,name)}return UpgradeHelper.getDirective=function($injector,name){var directives=$injector.get(name+"Directive");if(directives.length>1)throw new Error("Only support single directive definition for: "+name);var directive=directives[0];return directive.compile&&!directive.link&&notSupported(name,"compile"),directive.replace&&notSupported(name,"replace"),directive.terminal&&notSupported(name,"terminal"),directive},UpgradeHelper.getTemplate=function($injector,directive,fetchRemoteTemplate){if(void 0===fetchRemoteTemplate&&(fetchRemoteTemplate=!1),void 0!==directive.template)return getOrCall(directive.template);if(directive.templateUrl){var $templateCache_1=$injector.get($TEMPLATE_CACHE),url_1=getOrCall(directive.templateUrl),template=$templateCache_1.get(url_1);if(void 0!==template)return template;if(!fetchRemoteTemplate)throw new Error("loading directive templates asynchronously is not supported");return new Promise(function(resolve,reject){var $httpBackend=$injector.get($HTTP_BACKEND);$httpBackend("GET",url_1,null,function(status,response){200===status?resolve($templateCache_1.put(url_1,response)):reject("GET component template from '"+url_1+"' returned '"+status+": "+response+"'")})})}throw new Error("Directive '"+directive.name+"' is not a component, it is missing template.")},UpgradeHelper.prototype.buildController=function(controllerType,$scope){var locals={$scope:$scope,$element:this.$element},controller=this.$controller(controllerType,locals,null,this.directive.controllerAs);return this.$element.data(controllerKey(this.directive.name),controller),controller},UpgradeHelper.prototype.compileTemplate=function(template){return void 0===template&&(template=UpgradeHelper.getTemplate(this.$injector,this.directive)),this.compileHtml(template)},UpgradeHelper.prototype.prepareTransclusion=function(){var _this=this,transclude=this.directive.transclude,contentChildNodes=this.extractChildNodes(),$template=contentChildNodes,attachChildrenFn=function(scope,cloneAttach){return cloneAttach($template,scope)};if(transclude){var slots_1=Object.create(null);if("object"==typeof transclude){$template=[];var slotMap_1=Object.create(null),filledSlots_1=Object.create(null);Object.keys(transclude).forEach(function(slotName){var selector=transclude[slotName],optional="?"===selector.charAt(0);selector=optional?selector.substring(1):selector,slotMap_1[selector]=slotName,slots_1[slotName]=null,filledSlots_1[slotName]=optional}),contentChildNodes.forEach(function(node){var slotName=slotMap_1[directiveNormalize(node.nodeName.toLowerCase())];slotName?(filledSlots_1[slotName]=!0,slots_1[slotName]=slots_1[slotName]||[],slots_1[slotName].push(node)):$template.push(node)}),Object.keys(filledSlots_1).forEach(function(slotName){if(!filledSlots_1[slotName])throw new Error("Required transclusion slot '"+slotName+"' on directive: "+_this.name)}),Object.keys(slots_1).filter(function(slotName){return slots_1[slotName]}).forEach(function(slotName){var nodes=slots_1[slotName];slots_1[slotName]=function(scope,cloneAttach){return cloneAttach(nodes,scope)}})}attachChildrenFn.$$slots=slots_1,$template.forEach(function(node){node.nodeType!==Node.TEXT_NODE||node.nodeValue||(node.nodeValue="‌")})}return attachChildrenFn},UpgradeHelper.prototype.resolveAndBindRequiredControllers=function(controllerInstance){var directiveRequire=this.getDirectiveRequire(),requiredControllers=this.resolveRequire(directiveRequire);if(controllerInstance&&this.directive.bindToController&&isMap(directiveRequire)){var requiredControllersMap_1=requiredControllers;Object.keys(requiredControllersMap_1).forEach(function(key){controllerInstance[key]=requiredControllersMap_1[key]})}return requiredControllers},UpgradeHelper.prototype.compileHtml=function(html){return this.element.innerHTML=html,this.$compile(this.element.childNodes)},UpgradeHelper.prototype.extractChildNodes=function(){for(var childNode,childNodes=[];childNode=this.element.firstChild;)this.element.removeChild(childNode),childNodes.push(childNode);return childNodes},UpgradeHelper.prototype.getDirectiveRequire=function(){var require=this.directive.require||this.directive.controller&&this.directive.name;return isMap(require)&&Object.keys(require).forEach(function(key){var value=require[key],match=value.match(REQUIRE_PREFIX_RE),name=value.substring(match[0].length);name||(require[key]=match[0]+key)}),require},UpgradeHelper.prototype.resolveRequire=function(require,controllerInstance){var _this=this;if(require){if(Array.isArray(require))return require.map(function(req){return _this.resolveRequire(req)});if("object"==typeof require){var value_1={};return Object.keys(require).forEach(function(key){return value_1[key]=_this.resolveRequire(require[key])}),value_1}if("string"==typeof require){var match=require.match(REQUIRE_PREFIX_RE),inheritType=match[1]||match[3],name=require.substring(match[0].length),isOptional=!!match[2],searchParents=!!inheritType,startOnParent="^^"===inheritType,ctrlKey=controllerKey(name),elem=startOnParent?this.$element.parent():this.$element,value=searchParents?elem.inheritedData(ctrlKey):elem.data(ctrlKey);if(!value&&!isOptional)throw new Error("Unable to find required '"+require+"' in upgraded directive '"+this.name+"'.");return value}throw new Error("Unrecognized 'require' syntax on upgraded directive '"+this.name+"': "+require)}return null},UpgradeHelper}(),CAMEL_CASE=/([A-Z])/g,INITIAL_VALUE$1={__UNINITIALIZED__:!0},NOT_SUPPORTED="NOT_SUPPORTED",UpgradeNg1ComponentAdapterBuilder=function(){function UpgradeNg1ComponentAdapterBuilder(name){this.name=name,this.inputs=[],this.inputsRename=[],this.outputs=[],this.outputsRename=[],this.propertyOutputs=[],this.checkProperties=[],this.propertyMap={},this.directive=null;var selector=name.replace(CAMEL_CASE,function(all,next){return"-"+next.toLowerCase()}),self=this;this.type=_angular_core.Directive({selector:selector,inputs:this.inputsRename,outputs:this.outputsRename}).Class({constructor:[new _angular_core.Inject($SCOPE),_angular_core.Injector,_angular_core.ElementRef,function(scope,injector,elementRef){var helper=new UpgradeHelper(injector,name,elementRef,this.directive);return new UpgradeNg1ComponentAdapter(helper,scope,self.template,self.inputs,self.outputs,self.propertyOutputs,self.checkProperties,self.propertyMap)}],ngOnInit:function(){},ngOnChanges:function(){},ngDoCheck:function(){},ngOnDestroy:function(){}})}return UpgradeNg1ComponentAdapterBuilder.prototype.extractBindings=function(){var _this=this,btcIsObject="object"==typeof this.directive.bindToController;if(btcIsObject&&Object.keys(this.directive.scope).length)throw new Error("Binding definitions on scope and controller at the same time are not supported.");var context=btcIsObject?this.directive.bindToController:this.directive.scope;"object"==typeof context&&Object.keys(context).forEach(function(propName){var definition=context[propName],bindingType=definition.charAt(0),bindingOptions=definition.charAt(1),attrName=definition.substring("?"===bindingOptions?2:1)||propName,inputName="input_"+attrName,inputNameRename=inputName+": "+attrName,outputName="output_"+attrName,outputNameRename=outputName+": "+attrName,outputNameRenameChange=outputNameRename+"Change";switch(bindingType){case"@":case"<":_this.inputs.push(inputName),_this.inputsRename.push(inputNameRename),_this.propertyMap[inputName]=propName;break;case"=":_this.inputs.push(inputName),_this.inputsRename.push(inputNameRename),_this.propertyMap[inputName]=propName,_this.outputs.push(outputName),_this.outputsRename.push(outputNameRenameChange),_this.propertyMap[outputName]=propName,_this.checkProperties.push(propName),_this.propertyOutputs.push(outputName);break;case"&":_this.outputs.push(outputName),_this.outputsRename.push(outputNameRename),_this.propertyMap[outputName]=propName;break;default:var json=JSON.stringify(context);throw new Error("Unexpected mapping '"+bindingType+"' in '"+json+"' in '"+_this.name+"' directive.")}})},UpgradeNg1ComponentAdapterBuilder.resolve=function(exportedComponents,$injector){var promises=Object.keys(exportedComponents).map(function(name){var exportedComponent=exportedComponents[name];return exportedComponent.directive=UpgradeHelper.getDirective($injector,name),exportedComponent.extractBindings(),Promise.resolve(UpgradeHelper.getTemplate($injector,exportedComponent.directive,!0)).then(function(template){return exportedComponent.template=template})});return Promise.all(promises)},UpgradeNg1ComponentAdapterBuilder}(),UpgradeNg1ComponentAdapter=function(){function UpgradeNg1ComponentAdapter(helper,scope,template,inputs,outputs,propOuts,checkProperties,propertyMap){this.helper=helper,this.template=template,this.inputs=inputs,this.outputs=outputs,this.propOuts=propOuts,this.checkProperties=checkProperties,this.propertyMap=propertyMap,this.controllerInstance=null,this.destinationObj=null,this.checkLastValues=[],this.$element=null,this.directive=helper.directive,this.element=helper.element,this.$element=helper.$element,this.componentScope=scope.$new(!!this.directive.scope);var controllerType=this.directive.controller;this.directive.bindToController&&controllerType?(this.controllerInstance=this.helper.buildController(controllerType,this.componentScope),this.destinationObj=this.controllerInstance):this.destinationObj=this.componentScope;for(var i=0;i<inputs.length;i++)this[inputs[i]]=null;for(var j=0;j<outputs.length;j++){var emitter=this[outputs[j]]=new _angular_core.EventEmitter;this.setComponentProperty(outputs[j],function(emitter){return function(value){return emitter.emit(value)}}(emitter))}for(var k=0;k<propOuts.length;k++)this.checkLastValues.push(INITIAL_VALUE$1)}return UpgradeNg1ComponentAdapter.prototype.ngOnInit=function(){var attachChildNodes=this.helper.prepareTransclusion(),linkFn=this.helper.compileTemplate(this.template),controllerType=this.directive.controller,bindToController=this.directive.bindToController;controllerType&&!bindToController&&(this.controllerInstance=this.helper.buildController(controllerType,this.componentScope));var requiredControllers=this.helper.resolveAndBindRequiredControllers(this.controllerInstance);this.controllerInstance&&isFunction(this.controllerInstance.$onInit)&&this.controllerInstance.$onInit();var link=this.directive.link,preLink="object"==typeof link&&link.pre,postLink="object"==typeof link?link.post:link,attrs=NOT_SUPPORTED,transcludeFn=NOT_SUPPORTED;preLink&&preLink(this.componentScope,this.$element,attrs,requiredControllers,transcludeFn),linkFn(this.componentScope,null,{parentBoundTranscludeFn:attachChildNodes}),postLink&&postLink(this.componentScope,this.$element,attrs,requiredControllers,transcludeFn),this.controllerInstance&&isFunction(this.controllerInstance.$postLink)&&this.controllerInstance.$postLink()},UpgradeNg1ComponentAdapter.prototype.ngOnChanges=function(changes){var _this=this,ng1Changes={};Object.keys(changes).forEach(function(name){var change=changes[name];_this.setComponentProperty(name,change.currentValue),ng1Changes[_this.propertyMap[name]]=change}),isFunction(this.destinationObj.$onChanges)&&this.destinationObj.$onChanges(ng1Changes)},UpgradeNg1ComponentAdapter.prototype.ngDoCheck=function(){var _this=this,destinationObj=this.destinationObj,lastValues=this.checkLastValues,checkProperties=this.checkProperties,propOuts=this.propOuts;checkProperties.forEach(function(propName,i){var value=destinationObj[propName],last=lastValues[i];if(!strictEquals(last,value)){var eventEmitter=_this[propOuts[i]];eventEmitter.emit(lastValues[i]=value)}}),this.controllerInstance&&isFunction(this.controllerInstance.$doCheck)&&this.controllerInstance.$doCheck()},UpgradeNg1ComponentAdapter.prototype.ngOnDestroy=function(){this.controllerInstance&&isFunction(this.controllerInstance.$onDestroy)&&this.controllerInstance.$onDestroy()},UpgradeNg1ComponentAdapter.prototype.setComponentProperty=function(name,value){this.destinationObj[this.propertyMap[name]]=value},UpgradeNg1ComponentAdapter}(),upgradeCount=0,UpgradeAdapter=function(){function UpgradeAdapter(ng2AppModule,compilerOptions){if(this.ng2AppModule=ng2AppModule,this.compilerOptions=compilerOptions,this.idPrefix="NG2_UPGRADE_"+upgradeCount++ +"_",this.downgradedComponents=[],this.ng1ComponentsToBeUpgraded={},this.upgradedProviders=[],this.moduleRef=null,!ng2AppModule)throw new Error("UpgradeAdapter cannot be instantiated without an NgModule of the Angular app.")}return UpgradeAdapter.prototype.downgradeNg2Component=function(component){return this.downgradedComponents.push(component),downgradeComponent({component:component})},UpgradeAdapter.prototype.upgradeNg1Component=function(name){return this.ng1ComponentsToBeUpgraded.hasOwnProperty(name)?this.ng1ComponentsToBeUpgraded[name].type:(this.ng1ComponentsToBeUpgraded[name]=new UpgradeNg1ComponentAdapterBuilder(name)).type},UpgradeAdapter.prototype.registerForNg1Tests=function(modules){var _this=this,windowNgMock=window.angular.mock;if(!windowNgMock||!windowNgMock.module)throw new Error("Failed to find 'angular.mock.module'.");this.declareNg1Module(modules),windowNgMock.module(this.ng1Module.name);var upgrade=new UpgradeAdapterRef;return this.ng2BootstrapDeferred.promise.then(function(ng1Injector){upgrade._bootstrapDone(_this.moduleRef,ng1Injector)},onError),upgrade},UpgradeAdapter.prototype.bootstrap=function(element$$1,modules,config){var _this=this;this.declareNg1Module(modules);var upgrade=new UpgradeAdapterRef,windowAngular=window.angular;windowAngular.resumeBootstrap=void 0,this.ngZone.run(function(){bootstrap(element$$1,[_this.ng1Module.name],config)});var ng1BootstrapPromise=new Promise(function(resolve){if(windowAngular.resumeBootstrap){var originalResumeBootstrap_1=windowAngular.resumeBootstrap;windowAngular.resumeBootstrap=function(){windowAngular.resumeBootstrap=originalResumeBootstrap_1,windowAngular.resumeBootstrap.apply(this,arguments),resolve()}}else resolve()});return Promise.all([this.ng2BootstrapDeferred.promise,ng1BootstrapPromise]).then(function(_a){var ng1Injector=_a[0];element(element$$1).data(controllerKey(INJECTOR_KEY),_this.moduleRef.injector),_this.moduleRef.injector.get(_angular_core.NgZone).run(function(){upgrade._bootstrapDone(_this.moduleRef,ng1Injector)})},onError),upgrade},UpgradeAdapter.prototype.upgradeNg1Provider=function(name,options){var token=options&&options.asToken||name;this.upgradedProviders.push({provide:token,useFactory:function($injector){return $injector.get(name)},deps:[$INJECTOR]})},UpgradeAdapter.prototype.downgradeNg2Provider=function(token){return downgradeInjectable(token)},UpgradeAdapter.prototype.declareNg1Module=function(modules){var _this=this;void 0===modules&&(modules=[]);var original$applyFn,rootScopePrototype,rootScope,delayApplyExps=[],upgradeAdapter=this,ng1Module=this.ng1Module=module$1(this.idPrefix,modules),platformRef=_angular_platformBrowserDynamic.platformBrowserDynamic();return this.ngZone=new _angular_core.NgZone({enableLongStackTrace:Zone.hasOwnProperty("longStackTraceZoneSpec")}),this.ng2BootstrapDeferred=new Deferred,ng1Module.factory(INJECTOR_KEY,function(){return _this.moduleRef.injector.get(_angular_core.Injector)}).constant(NG_ZONE_KEY,this.ngZone).factory(COMPILER_KEY,function(){return _this.moduleRef.injector.get(_angular_core.Compiler)}).config(["$provide","$injector",function(provide,ng1Injector){provide.decorator($ROOT_SCOPE,["$delegate",function(rootScopeDelegate){if(rootScopePrototype=rootScopeDelegate.constructor.prototype,!rootScopePrototype.hasOwnProperty("$apply"))throw new Error("Failed to find '$apply' on '$rootScope'!");return original$applyFn=rootScopePrototype.$apply,rootScopePrototype.$apply=function(exp){return delayApplyExps.push(exp)},rootScope=rootScopeDelegate}]),ng1Injector.has($$TESTABILITY)&&provide.decorator($$TESTABILITY,["$delegate",function(testabilityDelegate){var originalWhenStable=testabilityDelegate.whenStable,newWhenStable=function(callback){originalWhenStable.call(this,function(){var ng2Testability=upgradeAdapter.moduleRef.injector.get(_angular_core.Testability);ng2Testability.isStable()?callback.apply(this,arguments):ng2Testability.whenStable(newWhenStable.bind(this,callback))})};return testabilityDelegate.whenStable=newWhenStable,testabilityDelegate}])}]),ng1Module.run(["$injector","$rootScope",function(ng1Injector,rootScope){UpgradeNg1ComponentAdapterBuilder.resolve(_this.ng1ComponentsToBeUpgraded,ng1Injector).then(function(){var DynamicNgUpgradeModule=_angular_core.NgModule({providers:[{provide:$INJECTOR,useFactory:function(){return ng1Injector}},{provide:$COMPILE,useFactory:function(){return ng1Injector.get($COMPILE)}},_this.upgradedProviders],imports:[_this.ng2AppModule],entryComponents:_this.downgradedComponents}).Class({constructor:function(){},ngDoBootstrap:function(){}});platformRef._bootstrapModuleWithZone(DynamicNgUpgradeModule,_this.compilerOptions,_this.ngZone).then(function(ref){_this.moduleRef=ref,_this.ngZone.run(function(){if(rootScopePrototype){for(rootScopePrototype.$apply=original$applyFn;delayApplyExps.length;)rootScope.$apply(delayApplyExps.shift());rootScopePrototype=null}})}).then(function(){return _this.ng2BootstrapDeferred.resolve(ng1Injector)},onError).then(function(){var subscription=_this.ngZone.onMicrotaskEmpty.subscribe({next:function(){return rootScope.$digest()}});rootScope.$on("$destroy",function(){subscription.unsubscribe()})})}).catch(function(e){return _this.ng2BootstrapDeferred.reject(e)})}]),ng1Module},UpgradeAdapter}(),UpgradeAdapterRef=function(){function UpgradeAdapterRef(){this._readyFn=null,this.ng1RootScope=null,this.ng1Injector=null,this.ng2ModuleRef=null,this.ng2Injector=null}return UpgradeAdapterRef.prototype._bootstrapDone=function(ngModuleRef,ng1Injector){this.ng2ModuleRef=ngModuleRef,this.ng2Injector=ngModuleRef.injector,this.ng1Injector=ng1Injector,this.ng1RootScope=ng1Injector.get($ROOT_SCOPE),this._readyFn&&this._readyFn(this)},UpgradeAdapterRef.prototype.ready=function(fn){this._readyFn=fn},UpgradeAdapterRef.prototype.dispose=function(){this.ng1Injector.get($ROOT_SCOPE).$destroy(),this.ng2ModuleRef.destroy()},UpgradeAdapterRef}();exports.VERSION=VERSION,exports.UpgradeAdapter=UpgradeAdapter,exports.UpgradeAdapterRef=UpgradeAdapterRef,Object.defineProperty(exports,"__esModule",{value:!0})});
var VERSION=new _angular_core.Version("4.3.0"),angular={bootstrap:noNg,module:noNg,element:noNg,version:noNg,resumeBootstrap:noNg,getTestability:noNg};try{window.hasOwnProperty("angular")&&(angular=window.angular)}catch(e){}var _matches,bootstrap=function(e,modules,config){return angular.bootstrap(e,modules,config)},module$1=function(prefix,dependencies){return angular.module(prefix,dependencies)},element=function(e){return angular.element(e)},$COMPILE="$compile",$CONTROLLER="$controller",$HTTP_BACKEND="$httpBackend",$INJECTOR="$injector",$PARSE="$parse",$ROOT_SCOPE="$rootScope",$SCOPE="$scope",$TEMPLATE_CACHE="$templateCache",$$TESTABILITY="$$testability",COMPILER_KEY="$$angularCompiler",INJECTOR_KEY="$$angularInjector",NG_ZONE_KEY="$$angularNgZone",REQUIRE_INJECTOR="?^^"+INJECTOR_KEY,REQUIRE_NG_MODEL="?ngModel",PropertyBinding=function(){function PropertyBinding(prop,attr){this.prop=prop,this.attr=attr,this.parseBinding()}return PropertyBinding.prototype.parseBinding=function(){this.bracketAttr="["+this.attr+"]",this.parenAttr="("+this.attr+")",this.bracketParenAttr="[("+this.attr+")]";var capitalAttr=this.attr.charAt(0).toUpperCase()+this.attr.substr(1);this.onAttr="on"+capitalAttr,this.bindAttr="bind"+capitalAttr,this.bindonAttr="bindon"+capitalAttr},PropertyBinding}(),DIRECTIVE_PREFIX_REGEXP=/^(?:x|data)[:\-_]/i,DIRECTIVE_SPECIAL_CHARS_REGEXP=/[:\-_]+(.)/g,Deferred=function(){function Deferred(){var _this=this;this.promise=new Promise(function(res,rej){_this.resolve=res,_this.reject=rej})}return Deferred}(),INITIAL_VALUE={__UNINITIALIZED__:!0},DowngradeComponentAdapter=function(){function DowngradeComponentAdapter(id,element,attrs,scope,ngModel,parentInjector,$injector,$compile,$parse,componentFactory){this.id=id,this.element=element,this.attrs=attrs,this.scope=scope,this.ngModel=ngModel,this.parentInjector=parentInjector,this.$injector=$injector,this.$compile=$compile,this.$parse=$parse,this.componentFactory=componentFactory,this.inputChangeCount=0,this.inputChanges=null,this.componentRef=null,this.component=null,this.changeDetector=null,this.element[0].id=id,this.componentScope=scope.$new()}return DowngradeComponentAdapter.prototype.compileContents=function(){var _this=this,compiledProjectableNodes=[],projectableNodes=this.groupProjectableNodes(),linkFns=projectableNodes.map(function(nodes){return _this.$compile(nodes)});return this.element.empty(),linkFns.forEach(function(linkFn){linkFn(_this.scope,function(clone){compiledProjectableNodes.push(clone),_this.element.append(clone)})}),compiledProjectableNodes},DowngradeComponentAdapter.prototype.createComponent=function(projectableNodes){var childInjector=_angular_core.ReflectiveInjector.resolveAndCreate([{provide:$SCOPE,useValue:this.componentScope}],this.parentInjector);this.componentRef=this.componentFactory.create(childInjector,projectableNodes,this.element[0]),this.changeDetector=this.componentRef.changeDetectorRef,this.component=this.componentRef.instance,hookupNgModel(this.ngModel,this.component)},DowngradeComponentAdapter.prototype.setupInputs=function(){for(var _this=this,attrs=this.attrs,inputs=this.componentFactory.inputs||[],_loop_1=function(i){var input=new PropertyBinding(inputs[i].propName,inputs[i].templateName),expr=null;if(attrs.hasOwnProperty(input.attr)){var observeFn_1=function(prop){var prevValue=INITIAL_VALUE;return function(currValue){strictEquals(prevValue,currValue)||(prevValue===INITIAL_VALUE&&(prevValue=currValue),_this.updateInput(prop,prevValue,currValue),prevValue=currValue)}}(input.prop);attrs.$observe(input.attr,observeFn_1);var unwatch_1=this_1.componentScope.$watch(function(){unwatch_1(""),unwatch_1=null,observeFn_1(attrs[input.attr])})}else attrs.hasOwnProperty(input.bindAttr)?expr=attrs[input.bindAttr]:attrs.hasOwnProperty(input.bracketAttr)?expr=attrs[input.bracketAttr]:attrs.hasOwnProperty(input.bindonAttr)?expr=attrs[input.bindonAttr]:attrs.hasOwnProperty(input.bracketParenAttr)&&(expr=attrs[input.bracketParenAttr]);if(null!=expr){var watchFn=function(prop){return function(currValue,prevValue){return _this.updateInput(prop,prevValue,currValue)}}(input.prop);this_1.componentScope.$watch(expr,watchFn)}},this_1=this,i=0;i<inputs.length;i++)_loop_1(i);var prototype=this.componentFactory.componentType.prototype;prototype&&prototype.ngOnChanges&&(this.inputChanges={},this.componentScope.$watch(function(){return _this.inputChangeCount},function(){var inputChanges=_this.inputChanges;_this.inputChanges={},_this.component.ngOnChanges(inputChanges)})),this.componentScope.$watch(function(){return _this.changeDetector&&_this.changeDetector.detectChanges()})},DowngradeComponentAdapter.prototype.setupOutputs=function(){for(var _this=this,attrs=this.attrs,outputs=this.componentFactory.outputs||[],j=0;j<outputs.length;j++){var output=new PropertyBinding(outputs[j].propName,outputs[j].templateName),expr=null,assignExpr=!1,bindonAttr=output.bindonAttr?output.bindonAttr.substring(0,output.bindonAttr.length-6):null,bracketParenAttr=output.bracketParenAttr?"[("+output.bracketParenAttr.substring(2,output.bracketParenAttr.length-8)+")]":null;if(attrs.hasOwnProperty(output.onAttr)?expr=attrs[output.onAttr]:attrs.hasOwnProperty(output.parenAttr)?expr=attrs[output.parenAttr]:attrs.hasOwnProperty(bindonAttr)?(expr=attrs[bindonAttr],assignExpr=!0):attrs.hasOwnProperty(bracketParenAttr)&&(expr=attrs[bracketParenAttr],assignExpr=!0),null!=expr&&null!=assignExpr){var getter=this.$parse(expr),setter=getter.assign;if(assignExpr&&!setter)throw new Error("Expression '"+expr+"' is not assignable!");var emitter=this.component[output.prop];if(!emitter)throw new Error("Missing emitter '"+output.prop+"' on component '"+getComponentName(this.componentFactory.componentType)+"'!");emitter.subscribe({next:assignExpr?function(setter){return function(v){return setter(_this.scope,v)}}(setter):function(getter){return function(v){return getter(_this.scope,{$event:v})}}(getter)})}}},DowngradeComponentAdapter.prototype.registerCleanup=function(){var _this=this;this.element.bind("$destroy",function(){_this.componentScope.$destroy(),_this.componentRef.destroy()})},DowngradeComponentAdapter.prototype.getInjector=function(){return this.componentRef&&this.componentRef.injector},DowngradeComponentAdapter.prototype.updateInput=function(prop,prevValue,currValue){this.inputChanges&&(this.inputChangeCount++,this.inputChanges[prop]=new _angular_core.SimpleChange(prevValue,currValue,prevValue===currValue)),this.component[prop]=currValue},DowngradeComponentAdapter.prototype.groupProjectableNodes=function(){var ngContentSelectors=this.componentFactory.ngContentSelectors;return groupNodesBySelector(ngContentSelectors,this.element.contents())},DowngradeComponentAdapter}(),downgradeCount=0,ParentInjectorPromise$1=function(){function ParentInjectorPromise$1(element){this.element=element,this.injectorKey=controllerKey(INJECTOR_KEY),this.callbacks=[],element.data(this.injectorKey,this)}return ParentInjectorPromise$1.prototype.then=function(callback){this.injector?callback(this.injector):this.callbacks.push(callback)},ParentInjectorPromise$1.prototype.resolve=function(injector){this.injector=injector,this.element.data(this.injectorKey,injector),this.element=null,this.callbacks.forEach(function(callback){return callback(injector)}),this.callbacks.length=0},ParentInjectorPromise$1}(),REQUIRE_PREFIX_RE=/^(\^\^?)?(\?)?(\^\^?)?/,UpgradeHelper=function(){function UpgradeHelper(injector,name,elementRef,directive){this.injector=injector,this.name=name,this.$injector=injector.get($INJECTOR),this.$compile=this.$injector.get($COMPILE),this.$controller=this.$injector.get($CONTROLLER),this.element=elementRef.nativeElement,this.$element=element(this.element),this.directive=directive||UpgradeHelper.getDirective(this.$injector,name)}return UpgradeHelper.getDirective=function($injector,name){var directives=$injector.get(name+"Directive");if(directives.length>1)throw new Error("Only support single directive definition for: "+name);var directive=directives[0];return directive.compile&&!directive.link&&notSupported(name,"compile"),directive.replace&&notSupported(name,"replace"),directive.terminal&&notSupported(name,"terminal"),directive},UpgradeHelper.getTemplate=function($injector,directive,fetchRemoteTemplate){if(void 0===fetchRemoteTemplate&&(fetchRemoteTemplate=!1),void 0!==directive.template)return getOrCall(directive.template);if(directive.templateUrl){var $templateCache_1=$injector.get($TEMPLATE_CACHE),url_1=getOrCall(directive.templateUrl),template=$templateCache_1.get(url_1);if(void 0!==template)return template;if(!fetchRemoteTemplate)throw new Error("loading directive templates asynchronously is not supported");return new Promise(function(resolve,reject){var $httpBackend=$injector.get($HTTP_BACKEND);$httpBackend("GET",url_1,null,function(status,response){200===status?resolve($templateCache_1.put(url_1,response)):reject("GET component template from '"+url_1+"' returned '"+status+": "+response+"'")})})}throw new Error("Directive '"+directive.name+"' is not a component, it is missing template.")},UpgradeHelper.prototype.buildController=function(controllerType,$scope){var locals={$scope:$scope,$element:this.$element},controller=this.$controller(controllerType,locals,null,this.directive.controllerAs);return this.$element.data(controllerKey(this.directive.name),controller),controller},UpgradeHelper.prototype.compileTemplate=function(template){return void 0===template&&(template=UpgradeHelper.getTemplate(this.$injector,this.directive)),this.compileHtml(template)},UpgradeHelper.prototype.prepareTransclusion=function(){var _this=this,transclude=this.directive.transclude,contentChildNodes=this.extractChildNodes(),$template=contentChildNodes,attachChildrenFn=function(scope,cloneAttach){return cloneAttach($template,scope)};if(transclude){var slots_1=Object.create(null);if("object"==typeof transclude){$template=[];var slotMap_1=Object.create(null),filledSlots_1=Object.create(null);Object.keys(transclude).forEach(function(slotName){var selector=transclude[slotName],optional="?"===selector.charAt(0);selector=optional?selector.substring(1):selector,slotMap_1[selector]=slotName,slots_1[slotName]=null,filledSlots_1[slotName]=optional}),contentChildNodes.forEach(function(node){var slotName=slotMap_1[directiveNormalize(node.nodeName.toLowerCase())];slotName?(filledSlots_1[slotName]=!0,slots_1[slotName]=slots_1[slotName]||[],slots_1[slotName].push(node)):$template.push(node)}),Object.keys(filledSlots_1).forEach(function(slotName){if(!filledSlots_1[slotName])throw new Error("Required transclusion slot '"+slotName+"' on directive: "+_this.name)}),Object.keys(slots_1).filter(function(slotName){return slots_1[slotName]}).forEach(function(slotName){var nodes=slots_1[slotName];slots_1[slotName]=function(scope,cloneAttach){return cloneAttach(nodes,scope)}})}attachChildrenFn.$$slots=slots_1,$template.forEach(function(node){node.nodeType!==Node.TEXT_NODE||node.nodeValue||(node.nodeValue="‌")})}return attachChildrenFn},UpgradeHelper.prototype.resolveAndBindRequiredControllers=function(controllerInstance){var directiveRequire=this.getDirectiveRequire(),requiredControllers=this.resolveRequire(directiveRequire);if(controllerInstance&&this.directive.bindToController&&isMap(directiveRequire)){var requiredControllersMap_1=requiredControllers;Object.keys(requiredControllersMap_1).forEach(function(key){controllerInstance[key]=requiredControllersMap_1[key]})}return requiredControllers},UpgradeHelper.prototype.compileHtml=function(html){return this.element.innerHTML=html,this.$compile(this.element.childNodes)},UpgradeHelper.prototype.extractChildNodes=function(){for(var childNode,childNodes=[];childNode=this.element.firstChild;)this.element.removeChild(childNode),childNodes.push(childNode);return childNodes},UpgradeHelper.prototype.getDirectiveRequire=function(){var require=this.directive.require||this.directive.controller&&this.directive.name;return isMap(require)&&Object.keys(require).forEach(function(key){var value=require[key],match=value.match(REQUIRE_PREFIX_RE),name=value.substring(match[0].length);name||(require[key]=match[0]+key)}),require},UpgradeHelper.prototype.resolveRequire=function(require,controllerInstance){var _this=this;if(require){if(Array.isArray(require))return require.map(function(req){return _this.resolveRequire(req)});if("object"==typeof require){var value_1={};return Object.keys(require).forEach(function(key){return value_1[key]=_this.resolveRequire(require[key])}),value_1}if("string"==typeof require){var match=require.match(REQUIRE_PREFIX_RE),inheritType=match[1]||match[3],name=require.substring(match[0].length),isOptional=!!match[2],searchParents=!!inheritType,startOnParent="^^"===inheritType,ctrlKey=controllerKey(name),elem=startOnParent?this.$element.parent():this.$element,value=searchParents?elem.inheritedData(ctrlKey):elem.data(ctrlKey);if(!value&&!isOptional)throw new Error("Unable to find required '"+require+"' in upgraded directive '"+this.name+"'.");return value}throw new Error("Unrecognized 'require' syntax on upgraded directive '"+this.name+"': "+require)}return null},UpgradeHelper}(),CAMEL_CASE=/([A-Z])/g,INITIAL_VALUE$1={__UNINITIALIZED__:!0},NOT_SUPPORTED="NOT_SUPPORTED",UpgradeNg1ComponentAdapterBuilder=function(){function UpgradeNg1ComponentAdapterBuilder(name){this.name=name,this.inputs=[],this.inputsRename=[],this.outputs=[],this.outputsRename=[],this.propertyOutputs=[],this.checkProperties=[],this.propertyMap={},this.directive=null;var selector=name.replace(CAMEL_CASE,function(all,next){return"-"+next.toLowerCase()}),self=this;this.type=_angular_core.Directive({selector:selector,inputs:this.inputsRename,outputs:this.outputsRename}).Class({constructor:[new _angular_core.Inject($SCOPE),_angular_core.Injector,_angular_core.ElementRef,function(scope,injector,elementRef){var helper=new UpgradeHelper(injector,name,elementRef,this.directive);return new UpgradeNg1ComponentAdapter(helper,scope,self.template,self.inputs,self.outputs,self.propertyOutputs,self.checkProperties,self.propertyMap)}],ngOnInit:function(){},ngOnChanges:function(){},ngDoCheck:function(){},ngOnDestroy:function(){}})}return UpgradeNg1ComponentAdapterBuilder.prototype.extractBindings=function(){var _this=this,btcIsObject="object"==typeof this.directive.bindToController;if(btcIsObject&&Object.keys(this.directive.scope).length)throw new Error("Binding definitions on scope and controller at the same time are not supported.");var context=btcIsObject?this.directive.bindToController:this.directive.scope;"object"==typeof context&&Object.keys(context).forEach(function(propName){var definition=context[propName],bindingType=definition.charAt(0),bindingOptions=definition.charAt(1),attrName=definition.substring("?"===bindingOptions?2:1)||propName,inputName="input_"+attrName,inputNameRename=inputName+": "+attrName,outputName="output_"+attrName,outputNameRename=outputName+": "+attrName,outputNameRenameChange=outputNameRename+"Change";switch(bindingType){case"@":case"<":_this.inputs.push(inputName),_this.inputsRename.push(inputNameRename),_this.propertyMap[inputName]=propName;break;case"=":_this.inputs.push(inputName),_this.inputsRename.push(inputNameRename),_this.propertyMap[inputName]=propName,_this.outputs.push(outputName),_this.outputsRename.push(outputNameRenameChange),_this.propertyMap[outputName]=propName,_this.checkProperties.push(propName),_this.propertyOutputs.push(outputName);break;case"&":_this.outputs.push(outputName),_this.outputsRename.push(outputNameRename),_this.propertyMap[outputName]=propName;break;default:var json=JSON.stringify(context);throw new Error("Unexpected mapping '"+bindingType+"' in '"+json+"' in '"+_this.name+"' directive.")}})},UpgradeNg1ComponentAdapterBuilder.resolve=function(exportedComponents,$injector){var promises=Object.keys(exportedComponents).map(function(name){var exportedComponent=exportedComponents[name];return exportedComponent.directive=UpgradeHelper.getDirective($injector,name),exportedComponent.extractBindings(),Promise.resolve(UpgradeHelper.getTemplate($injector,exportedComponent.directive,!0)).then(function(template){return exportedComponent.template=template})});return Promise.all(promises)},UpgradeNg1ComponentAdapterBuilder}(),UpgradeNg1ComponentAdapter=function(){function UpgradeNg1ComponentAdapter(helper,scope,template,inputs,outputs,propOuts,checkProperties,propertyMap){this.helper=helper,this.template=template,this.inputs=inputs,this.outputs=outputs,this.propOuts=propOuts,this.checkProperties=checkProperties,this.propertyMap=propertyMap,this.controllerInstance=null,this.destinationObj=null,this.checkLastValues=[],this.$element=null,this.directive=helper.directive,this.element=helper.element,this.$element=helper.$element,this.componentScope=scope.$new(!!this.directive.scope);var controllerType=this.directive.controller;this.directive.bindToController&&controllerType?(this.controllerInstance=this.helper.buildController(controllerType,this.componentScope),this.destinationObj=this.controllerInstance):this.destinationObj=this.componentScope;for(var i=0;i<inputs.length;i++)this[inputs[i]]=null;for(var j=0;j<outputs.length;j++){var emitter=this[outputs[j]]=new _angular_core.EventEmitter;this.setComponentProperty(outputs[j],function(emitter){return function(value){return emitter.emit(value)}}(emitter))}for(var k=0;k<propOuts.length;k++)this.checkLastValues.push(INITIAL_VALUE$1)}return UpgradeNg1ComponentAdapter.prototype.ngOnInit=function(){var attachChildNodes=this.helper.prepareTransclusion(),linkFn=this.helper.compileTemplate(this.template),controllerType=this.directive.controller,bindToController=this.directive.bindToController;controllerType&&!bindToController&&(this.controllerInstance=this.helper.buildController(controllerType,this.componentScope));var requiredControllers=this.helper.resolveAndBindRequiredControllers(this.controllerInstance);this.controllerInstance&&isFunction(this.controllerInstance.$onInit)&&this.controllerInstance.$onInit();var link=this.directive.link,preLink="object"==typeof link&&link.pre,postLink="object"==typeof link?link.post:link,attrs=NOT_SUPPORTED,transcludeFn=NOT_SUPPORTED;preLink&&preLink(this.componentScope,this.$element,attrs,requiredControllers,transcludeFn),linkFn(this.componentScope,null,{parentBoundTranscludeFn:attachChildNodes}),postLink&&postLink(this.componentScope,this.$element,attrs,requiredControllers,transcludeFn),this.controllerInstance&&isFunction(this.controllerInstance.$postLink)&&this.controllerInstance.$postLink()},UpgradeNg1ComponentAdapter.prototype.ngOnChanges=function(changes){var _this=this,ng1Changes={};Object.keys(changes).forEach(function(name){var change=changes[name];_this.setComponentProperty(name,change.currentValue),ng1Changes[_this.propertyMap[name]]=change}),isFunction(this.destinationObj.$onChanges)&&this.destinationObj.$onChanges(ng1Changes)},UpgradeNg1ComponentAdapter.prototype.ngDoCheck=function(){var _this=this,destinationObj=this.destinationObj,lastValues=this.checkLastValues,checkProperties=this.checkProperties,propOuts=this.propOuts;checkProperties.forEach(function(propName,i){var value=destinationObj[propName],last=lastValues[i];if(!strictEquals(last,value)){var eventEmitter=_this[propOuts[i]];eventEmitter.emit(lastValues[i]=value)}}),this.controllerInstance&&isFunction(this.controllerInstance.$doCheck)&&this.controllerInstance.$doCheck()},UpgradeNg1ComponentAdapter.prototype.ngOnDestroy=function(){this.controllerInstance&&isFunction(this.controllerInstance.$onDestroy)&&this.controllerInstance.$onDestroy()},UpgradeNg1ComponentAdapter.prototype.setComponentProperty=function(name,value){this.destinationObj[this.propertyMap[name]]=value},UpgradeNg1ComponentAdapter}(),upgradeCount=0,UpgradeAdapter=function(){function UpgradeAdapter(ng2AppModule,compilerOptions){if(this.ng2AppModule=ng2AppModule,this.compilerOptions=compilerOptions,this.idPrefix="NG2_UPGRADE_"+upgradeCount++ +"_",this.downgradedComponents=[],this.ng1ComponentsToBeUpgraded={},this.upgradedProviders=[],this.moduleRef=null,!ng2AppModule)throw new Error("UpgradeAdapter cannot be instantiated without an NgModule of the Angular app.")}return UpgradeAdapter.prototype.downgradeNg2Component=function(component){return this.downgradedComponents.push(component),downgradeComponent({component:component})},UpgradeAdapter.prototype.upgradeNg1Component=function(name){return this.ng1ComponentsToBeUpgraded.hasOwnProperty(name)?this.ng1ComponentsToBeUpgraded[name].type:(this.ng1ComponentsToBeUpgraded[name]=new UpgradeNg1ComponentAdapterBuilder(name)).type},UpgradeAdapter.prototype.registerForNg1Tests=function(modules){var _this=this,windowNgMock=window.angular.mock;if(!windowNgMock||!windowNgMock.module)throw new Error("Failed to find 'angular.mock.module'.");this.declareNg1Module(modules),windowNgMock.module(this.ng1Module.name);var upgrade=new UpgradeAdapterRef;return this.ng2BootstrapDeferred.promise.then(function(ng1Injector){upgrade._bootstrapDone(_this.moduleRef,ng1Injector)},onError),upgrade},UpgradeAdapter.prototype.bootstrap=function(element$$1,modules,config){var _this=this;this.declareNg1Module(modules);var upgrade=new UpgradeAdapterRef,windowAngular=window.angular;windowAngular.resumeBootstrap=void 0,this.ngZone.run(function(){bootstrap(element$$1,[_this.ng1Module.name],config)});var ng1BootstrapPromise=new Promise(function(resolve){if(windowAngular.resumeBootstrap){var originalResumeBootstrap_1=windowAngular.resumeBootstrap;windowAngular.resumeBootstrap=function(){windowAngular.resumeBootstrap=originalResumeBootstrap_1,windowAngular.resumeBootstrap.apply(this,arguments),resolve()}}else resolve()});return Promise.all([this.ng2BootstrapDeferred.promise,ng1BootstrapPromise]).then(function(_a){var ng1Injector=_a[0];element(element$$1).data(controllerKey(INJECTOR_KEY),_this.moduleRef.injector),_this.moduleRef.injector.get(_angular_core.NgZone).run(function(){upgrade._bootstrapDone(_this.moduleRef,ng1Injector)})},onError),upgrade},UpgradeAdapter.prototype.upgradeNg1Provider=function(name,options){var token=options&&options.asToken||name;this.upgradedProviders.push({provide:token,useFactory:function($injector){return $injector.get(name)},deps:[$INJECTOR]})},UpgradeAdapter.prototype.downgradeNg2Provider=function(token){return downgradeInjectable(token)},UpgradeAdapter.prototype.declareNg1Module=function(modules){var _this=this;void 0===modules&&(modules=[]);var original$applyFn,rootScopePrototype,rootScope,delayApplyExps=[],upgradeAdapter=this,ng1Module=this.ng1Module=module$1(this.idPrefix,modules),platformRef=_angular_platformBrowserDynamic.platformBrowserDynamic();return this.ngZone=new _angular_core.NgZone({enableLongStackTrace:Zone.hasOwnProperty("longStackTraceZoneSpec")}),this.ng2BootstrapDeferred=new Deferred,ng1Module.factory(INJECTOR_KEY,function(){return _this.moduleRef.injector.get(_angular_core.Injector)}).constant(NG_ZONE_KEY,this.ngZone).factory(COMPILER_KEY,function(){return _this.moduleRef.injector.get(_angular_core.Compiler)}).config(["$provide","$injector",function(provide,ng1Injector){provide.decorator($ROOT_SCOPE,["$delegate",function(rootScopeDelegate){if(rootScopePrototype=rootScopeDelegate.constructor.prototype,!rootScopePrototype.hasOwnProperty("$apply"))throw new Error("Failed to find '$apply' on '$rootScope'!");return original$applyFn=rootScopePrototype.$apply,rootScopePrototype.$apply=function(exp){return delayApplyExps.push(exp)},rootScope=rootScopeDelegate}]),ng1Injector.has($$TESTABILITY)&&provide.decorator($$TESTABILITY,["$delegate",function(testabilityDelegate){var originalWhenStable=testabilityDelegate.whenStable,newWhenStable=function(callback){originalWhenStable.call(this,function(){var ng2Testability=upgradeAdapter.moduleRef.injector.get(_angular_core.Testability);ng2Testability.isStable()?callback.apply(this,arguments):ng2Testability.whenStable(newWhenStable.bind(this,callback))})};return testabilityDelegate.whenStable=newWhenStable,testabilityDelegate}])}]),ng1Module.run(["$injector","$rootScope",function(ng1Injector,rootScope){UpgradeNg1ComponentAdapterBuilder.resolve(_this.ng1ComponentsToBeUpgraded,ng1Injector).then(function(){var DynamicNgUpgradeModule=_angular_core.NgModule({providers:[{provide:$INJECTOR,useFactory:function(){return ng1Injector}},{provide:$COMPILE,useFactory:function(){return ng1Injector.get($COMPILE)}},_this.upgradedProviders],imports:[_this.ng2AppModule],entryComponents:_this.downgradedComponents}).Class({constructor:function(){},ngDoBootstrap:function(){}});platformRef._bootstrapModuleWithZone(DynamicNgUpgradeModule,_this.compilerOptions,_this.ngZone).then(function(ref){_this.moduleRef=ref,_this.ngZone.run(function(){if(rootScopePrototype){for(rootScopePrototype.$apply=original$applyFn;delayApplyExps.length;)rootScope.$apply(delayApplyExps.shift());rootScopePrototype=null}})}).then(function(){return _this.ng2BootstrapDeferred.resolve(ng1Injector)},onError).then(function(){var subscription=_this.ngZone.onMicrotaskEmpty.subscribe({next:function(){return rootScope.$digest()}});rootScope.$on("$destroy",function(){subscription.unsubscribe()})})}).catch(function(e){return _this.ng2BootstrapDeferred.reject(e)})}]),ng1Module},UpgradeAdapter}(),UpgradeAdapterRef=function(){function UpgradeAdapterRef(){this._readyFn=null,this.ng1RootScope=null,this.ng1Injector=null,this.ng2ModuleRef=null,this.ng2Injector=null}return UpgradeAdapterRef.prototype._bootstrapDone=function(ngModuleRef,ng1Injector){this.ng2ModuleRef=ngModuleRef,this.ng2Injector=ngModuleRef.injector,this.ng1Injector=ng1Injector,this.ng1RootScope=ng1Injector.get($ROOT_SCOPE),this._readyFn&&this._readyFn(this)},UpgradeAdapterRef.prototype.ready=function(fn){this._readyFn=fn},UpgradeAdapterRef.prototype.dispose=function(){this.ng1Injector.get($ROOT_SCOPE).$destroy(),this.ng2ModuleRef.destroy()},UpgradeAdapterRef}();exports.VERSION=VERSION,exports.UpgradeAdapter=UpgradeAdapter,exports.UpgradeAdapterRef=UpgradeAdapterRef,Object.defineProperty(exports,"__esModule",{value:!0})});
//# sourceMappingURL=upgrade.umd.min.js.map
{
"name": "@angular/upgrade",
"version": "4.3.0-rc.0",
"version": "4.3.0",
"description": "Angular - the library for easing update from v1 to v2",

@@ -15,6 +15,6 @@ "main": "./bundles/upgrade.umd.js",

"peerDependencies": {
"@angular/core": "4.3.0-rc.0",
"@angular/compiler": "4.3.0-rc.0",
"@angular/platform-browser": "4.3.0-rc.0",
"@angular/platform-browser-dynamic": "4.3.0-rc.0"
"@angular/core": "4.3.0",
"@angular/compiler": "4.3.0",
"@angular/platform-browser": "4.3.0",
"@angular/platform-browser-dynamic": "4.3.0"
},

@@ -21,0 +21,0 @@ "repository": {

/**
* @license Angular v4.3.0-rc.0
* @license Angular v4.3.0
* (c) 2010-2017 Google, Inc. https://angular.io/

@@ -4,0 +4,0 @@ * License: MIT

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":3,"metadata":{"getAngularLib":{"__symbolic":"function","parameters":[],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":212,"character":4,"context":{"name":"angular"},"module":"./src/common/angular1"}},"setAngularLib":{"__symbolic":"function"},"downgradeComponent":{"__symbolic":"function"},"downgradeInjectable":{"__symbolic":"function"},"VERSION":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"Version"},"arguments":["4.3.0-rc.0"]},"UpgradeComponent":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"string"},{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"},{"__symbolic":"reference","module":"@angular/core","name":"Injector"}]}],"ngOnInit":[{"__symbolic":"method"}],"ngOnChanges":[{"__symbolic":"method"}],"ngDoCheck":[{"__symbolic":"method"}],"ngOnDestroy":[{"__symbolic":"method"}],"initializeBindings":[{"__symbolic":"method"}],"initializeOutputs":[{"__symbolic":"method"}],"bindOutputs":[{"__symbolic":"method"}],"forwardChanges":[{"__symbolic":"method"}]}},"UpgradeModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule"},"arguments":[{"providers":[{"__symbolic":"reference","name":"ɵe"}]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"Injector"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"bootstrap":[{"__symbolic":"method"}]}},"ɵa":{"__symbolic":"function"},"ɵb":{"__symbolic":"function","parameters":["i"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"i"},"member":"get"},"arguments":["$rootScope"]}},"ɵc":{"__symbolic":"function","parameters":["i"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"i"},"member":"get"},"arguments":["$compile"]}},"ɵd":{"__symbolic":"function","parameters":["i"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"i"},"member":"get"},"arguments":["$parse"]}},"ɵe":[{"provide":"$injector","useFactory":{"__symbolic":"reference","name":"ɵa"}},{"provide":"$rootScope","useFactory":{"__symbolic":"reference","name":"ɵb"},"deps":["$injector"]},{"provide":"$compile","useFactory":{"__symbolic":"reference","name":"ɵc"},"deps":["$injector"]},{"provide":"$parse","useFactory":{"__symbolic":"reference","name":"ɵd"},"deps":["$injector"]}]},"origins":{"getAngularLib":"./src/common/angular1","setAngularLib":"./src/common/angular1","downgradeComponent":"./src/common/downgrade_component","downgradeInjectable":"./src/common/downgrade_injectable","VERSION":"./src/common/version","UpgradeComponent":"./src/static/upgrade_component","UpgradeModule":"./src/static/upgrade_module","ɵa":"./src/static/angular1_providers","ɵb":"./src/static/angular1_providers","ɵc":"./src/static/angular1_providers","ɵd":"./src/static/angular1_providers","ɵe":"./src/static/angular1_providers"},"importAs":"@angular/upgrade/static"}
{"__symbolic":"module","version":3,"metadata":{"getAngularLib":{"__symbolic":"function","parameters":[],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":212,"character":4,"context":{"name":"angular"},"module":"./src/common/angular1"}},"setAngularLib":{"__symbolic":"function"},"downgradeComponent":{"__symbolic":"function"},"downgradeInjectable":{"__symbolic":"function"},"VERSION":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"Version"},"arguments":["4.3.0"]},"UpgradeComponent":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"string"},{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"},{"__symbolic":"reference","module":"@angular/core","name":"Injector"}]}],"ngOnInit":[{"__symbolic":"method"}],"ngOnChanges":[{"__symbolic":"method"}],"ngDoCheck":[{"__symbolic":"method"}],"ngOnDestroy":[{"__symbolic":"method"}],"initializeBindings":[{"__symbolic":"method"}],"initializeOutputs":[{"__symbolic":"method"}],"bindOutputs":[{"__symbolic":"method"}],"forwardChanges":[{"__symbolic":"method"}]}},"UpgradeModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule"},"arguments":[{"providers":[{"__symbolic":"reference","name":"ɵe"}]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"Injector"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"bootstrap":[{"__symbolic":"method"}]}},"ɵa":{"__symbolic":"function"},"ɵb":{"__symbolic":"function","parameters":["i"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"i"},"member":"get"},"arguments":["$rootScope"]}},"ɵc":{"__symbolic":"function","parameters":["i"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"i"},"member":"get"},"arguments":["$compile"]}},"ɵd":{"__symbolic":"function","parameters":["i"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"i"},"member":"get"},"arguments":["$parse"]}},"ɵe":[{"provide":"$injector","useFactory":{"__symbolic":"reference","name":"ɵa"}},{"provide":"$rootScope","useFactory":{"__symbolic":"reference","name":"ɵb"},"deps":["$injector"]},{"provide":"$compile","useFactory":{"__symbolic":"reference","name":"ɵc"},"deps":["$injector"]},{"provide":"$parse","useFactory":{"__symbolic":"reference","name":"ɵd"},"deps":["$injector"]}]},"origins":{"getAngularLib":"./src/common/angular1","setAngularLib":"./src/common/angular1","downgradeComponent":"./src/common/downgrade_component","downgradeInjectable":"./src/common/downgrade_injectable","VERSION":"./src/common/version","UpgradeComponent":"./src/static/upgrade_component","UpgradeModule":"./src/static/upgrade_module","ɵa":"./src/static/angular1_providers","ɵb":"./src/static/angular1_providers","ɵc":"./src/static/angular1_providers","ɵd":"./src/static/angular1_providers","ɵe":"./src/static/angular1_providers"},"importAs":"@angular/upgrade/static"}

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":3,"metadata":{"VERSION":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"Version"},"arguments":["4.3.0-rc.0"]},"UpgradeAdapter":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Type","module":"@angular/core","arguments":[{"__symbolic":"reference","name":"any"}]},{"__symbolic":"reference","module":"@angular/core","name":"CompilerOptions"}]}],"downgradeNg2Component":[{"__symbolic":"method"}],"upgradeNg1Component":[{"__symbolic":"method"}],"registerForNg1Tests":[{"__symbolic":"method"}],"bootstrap":[{"__symbolic":"method"}],"upgradeNg1Provider":[{"__symbolic":"method"}],"downgradeNg2Provider":[{"__symbolic":"method"}],"declareNg1Module":[{"__symbolic":"method"}]}},"UpgradeAdapterRef":{"__symbolic":"class","members":{"_bootstrapDone":[{"__symbolic":"method"}],"ready":[{"__symbolic":"method"}],"dispose":[{"__symbolic":"method"}]}}},"origins":{"VERSION":"./src/common/version","UpgradeAdapter":"./src/dynamic/upgrade_adapter","UpgradeAdapterRef":"./src/dynamic/upgrade_adapter"},"importAs":"@angular/upgrade"}
{"__symbolic":"module","version":3,"metadata":{"VERSION":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"Version"},"arguments":["4.3.0"]},"UpgradeAdapter":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Type","module":"@angular/core","arguments":[{"__symbolic":"reference","name":"any"}]},{"__symbolic":"reference","module":"@angular/core","name":"CompilerOptions"}]}],"downgradeNg2Component":[{"__symbolic":"method"}],"upgradeNg1Component":[{"__symbolic":"method"}],"registerForNg1Tests":[{"__symbolic":"method"}],"bootstrap":[{"__symbolic":"method"}],"upgradeNg1Provider":[{"__symbolic":"method"}],"downgradeNg2Provider":[{"__symbolic":"method"}],"declareNg1Module":[{"__symbolic":"method"}]}},"UpgradeAdapterRef":{"__symbolic":"class","members":{"_bootstrapDone":[{"__symbolic":"method"}],"ready":[{"__symbolic":"method"}],"dispose":[{"__symbolic":"method"}]}}},"origins":{"VERSION":"./src/common/version","UpgradeAdapter":"./src/dynamic/upgrade_adapter","UpgradeAdapterRef":"./src/dynamic/upgrade_adapter"},"importAs":"@angular/upgrade"}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc