From 9998263b9cc2761b1e393cb29328a97195ba57ae Mon Sep 17 00:00:00 2001 From: Sergey Akopkokhyants Date: Thu, 7 Apr 2016 22:42:32 +0200 Subject: [PATCH] feat(): Updated to Angular 2.0.0-beta.14 --- bundles/ng2-toasty.js | 35 ++++++++++++++++++++--------------- bundles/ng2-toasty.min.js | 2 +- package.json | 2 +- 3 files changed, 22 insertions(+), 17 deletions(-) diff --git a/bundles/ng2-toasty.js b/bundles/ng2-toasty.js index 92b6ded..07d686f 100644 --- a/bundles/ng2-toasty.js +++ b/bundles/ng2-toasty.js @@ -1,8 +1,8 @@ System.registerDynamic("src/toasty.container", ["angular2/core", "angular2/common", "angular2/src/facade/lang", "./toasty.config", "./toasty.service", "./toasty.component"], true, function($__require, exports, module) { ; - var define, - global = this, - GLOBAL = this; + var global = this, + __define = global.define; + global.define = undefined; var __decorate = (this && this.__decorate) || function(decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, @@ -104,14 +104,15 @@ System.registerDynamic("src/toasty.container", ["angular2/core", "angular2/commo return Toasty; })(); exports.Toasty = Toasty; + global.define = __define; return module.exports; }); System.registerDynamic("src/toasty.component", ["angular2/core", "angular2/common"], true, function($__require, exports, module) { ; - var define, - global = this, - GLOBAL = this; + var global = this, + __define = global.define; + global.define = undefined; var __decorate = (this && this.__decorate) || function(decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, @@ -148,14 +149,15 @@ System.registerDynamic("src/toasty.component", ["angular2/core", "angular2/commo return Toast; })(); exports.Toast = Toast; + global.define = __define; return module.exports; }); System.registerDynamic("src/toasty.config", ["angular2/core"], true, function($__require, exports, module) { ; - var define, - global = this, - GLOBAL = this; + var global = this, + __define = global.define; + global.define = undefined; var __decorate = (this && this.__decorate) || function(decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, @@ -185,14 +187,15 @@ System.registerDynamic("src/toasty.config", ["angular2/core"], true, function($_ return ToastyConfig; })(); exports.ToastyConfig = ToastyConfig; + global.define = __define; return module.exports; }); System.registerDynamic("src/toasty.service", ["angular2/core", "angular2/src/facade/lang", "rxjs/Observable", "./toasty.config"], true, function($__require, exports, module) { ; - var define, - global = this, - GLOBAL = this; + var global = this, + __define = global.define; + global.define = undefined; var __decorate = (this && this.__decorate) || function(decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, @@ -310,15 +313,16 @@ System.registerDynamic("src/toasty.service", ["angular2/core", "angular2/src/fac return ToastyService; })(); exports.ToastyService = ToastyService; + global.define = __define; return module.exports; }); System.registerDynamic("ng2-toasty", ["./src/toasty.container", "./src/toasty.component", "./src/toasty.config", "./src/toasty.service"], true, function($__require, exports, module) { "use strict"; ; - var define, - global = this, - GLOBAL = this; + var global = this, + __define = global.define; + global.define = undefined; function __export(m) { for (var p in m) if (!exports.hasOwnProperty(p)) @@ -337,5 +341,6 @@ System.registerDynamic("ng2-toasty", ["./src/toasty.container", "./src/toasty.co providers: [toasty_config_1.ToastyConfig, toasty_service_1.ToastyService], directives: [toasty_container_1.Toasty, toasty_component_1.Toast] }; + global.define = __define; return module.exports; }); diff --git a/bundles/ng2-toasty.min.js b/bundles/ng2-toasty.min.js index f683f70..bde7d6e 100644 --- a/bundles/ng2-toasty.min.js +++ b/bundles/ng2-toasty.min.js @@ -1,2 +1,2 @@ -System.registerDynamic("src/toasty.container",["angular2/core","angular2/common","angular2/src/facade/lang","./toasty.config","./toasty.service","./toasty.component"],!0,function(t,e,o){var n=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},s=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},i=t("angular2/core"),a=t("angular2/common"),r=t("angular2/src/facade/lang"),c=t("./toasty.config"),l=t("./toasty.service"),f=t("./toasty.component"),u=function(){function t(t,e){this.config=t,this.toastyService=e,this.toasts=[]}return t.prototype.ngOnInit=function(){var e=this;if(this.toastyService.getToasts().subscribe(function(t){e.toasts.length>=e.config.limit&&e.toasts.shift(),e.toasts.push(t),t.timeout&&e._setTimeout(t)}),this.toastyService.getClear().subscribe(function(){e.clearAll()}),this.position){for(var o=!0,n=0;n\n \n '}),s("design:paramtypes",[c.ToastyConfig,l.ToastyService])],t)}();return e.Toasty=u,o.exports}),System.registerDynamic("src/toasty.component",["angular2/core","angular2/common"],!0,function(t,e,o){var n=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},s=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},i=t("angular2/core"),a=t("angular2/common"),r=function(){function t(){this.closeToastEvent=new i.EventEmitter}return t.prototype.close=function(t){t.preventDefault(),this.closeToastEvent.next(this.toast)},n([i.Input(),s("design:type",Object)],t.prototype,"toast",void 0),n([i.Output("closeToast"),s("design:type",Object)],t.prototype,"closeToastEvent",void 0),t=n([i.Component({selector:"ng2-toast",directives:[a.CORE_DIRECTIVES],template:'\n
\n
\n
\n {{toast.title}}\n
\n {{toast.msg}}\n
\n
'}),s("design:paramtypes",[])],t)}();return e.Toast=r,o.exports}),System.registerDynamic("src/toasty.config",["angular2/core"],!0,function(t,e,o){var n=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},s=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},i=t("angular2/core"),a=function(){function t(){this.limit=5,this.showClose=!0,this.position="bottom-right",this.timeout=5e3,this.theme="default"}return t=n([i.Injectable(),s("design:paramtypes",[])],t)}();return e.ToastyConfig=a,o.exports}),System.registerDynamic("src/toasty.service",["angular2/core","angular2/src/facade/lang","rxjs/Observable","./toasty.config"],!0,function(t,e,o){var n=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},s=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},i=t("angular2/core"),a=t("angular2/src/facade/lang"),r=t("rxjs/Observable"),c=t("./toasty.config"),l=function(){function t(t){var e=this;this.config=t,this.uniqueCounter=0,this.toastsObservable=new r.Observable(function(t){e.toastsSubscriber=t}),this.clearObservable=new r.Observable(function(t){e.clearSubscriber=t})}return t.prototype.getToasts=function(){return this.toastsObservable},t.prototype.getClear=function(){return this.clearObservable},t.prototype["default"]=function(t){this.add(t,"default")},t.prototype.info=function(t){this.add(t,"info")},t.prototype.success=function(t){this.add(t,"success")},t.prototype.wait=function(t){this.add(t,"wait")},t.prototype.error=function(t){this.add(t,"error")},t.prototype.warning=function(t){this.add(t,"warning")},t.prototype.add=function(e,o){var n;if(n=a.isString(e)&&""!==e||a.isNumber(e)?{title:e.toString()}:e,!n||!n.title&&!n.msg)throw new Error("ng2-toasty: No toast title or message specified!");o=o||"default",this.uniqueCounter++;var s,i=this._checkConfigItem(this.config,n,"showClose");s=n.theme&&t.THEMES.indexOf(n.theme)>-1?n.theme:this.config.theme;var r={id:this.uniqueCounter,title:n.title,msg:n.msg,showClose:i,type:"toasty-type-"+o,theme:"toasty-theme-"+s,onAdd:n.onAdd&&a.isFunction(n.onAdd)?n.onAdd:null,onRemove:n.onRemove&&a.isFunction(n.onRemove)?n.onRemove:null};n.timeout?r.timeout=n.timeout||this.config.timeout:r.timeout=null;try{this.toastsSubscriber.next(r),n.onAdd&&a.isFunction(n.onAdd)&&n.onAdd.call(this,r)}catch(c){console.log(c),console.log("!!! Suggestion: Seems you forget add into your html?")}},t.prototype.clearAll=function(){this.clearSubscriber.next()},t.prototype._checkConfigItem=function(t,e,o){return e[o]===!1?!1:e[o]?!0:t[o]},t.THEMES=["default","material","bootstrap"],t=n([i.Injectable(),s("design:paramtypes",[c.ToastyConfig])],t)}();return e.ToastyService=l,o.exports}),System.registerDynamic("ng2-toasty",["./src/toasty.container","./src/toasty.component","./src/toasty.config","./src/toasty.service"],!0,function(t,e,o){"use strict";function n(t){for(var o in t)e.hasOwnProperty(o)||(e[o]=t[o])}var s=t("./src/toasty.container"),i=t("./src/toasty.component"),a=t("./src/toasty.config"),r=t("./src/toasty.service");return n(t("./src/toasty.container")),n(t("./src/toasty.component")),n(t("./src/toasty.config")),n(t("./src/toasty.service")),Object.defineProperty(e,"__esModule",{value:!0}),e["default"]={providers:[a.ToastyConfig,r.ToastyService],directives:[s.Toasty,i.Toast]},o.exports}); +System.registerDynamic("src/toasty.container",["angular2/core","angular2/common","angular2/src/facade/lang","./toasty.config","./toasty.service","./toasty.component"],!0,function(t,e,o){var n=this,s=n.define;n.define=void 0;var i=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},a=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},r=t("angular2/core"),c=t("angular2/common"),f=t("angular2/src/facade/lang"),l=t("./toasty.config"),u=t("./toasty.service"),p=t("./toasty.component"),d=function(){function t(t,e){this.config=t,this.toastyService=e,this.toasts=[]}return t.prototype.ngOnInit=function(){var e=this;if(this.toastyService.getToasts().subscribe(function(t){e.toasts.length>=e.config.limit&&e.toasts.shift(),e.toasts.push(t),t.timeout&&e._setTimeout(t)}),this.toastyService.getClear().subscribe(function(){e.clearAll()}),this.position){for(var o=!0,n=0;n\n \n '}),a("design:paramtypes",[l.ToastyConfig,u.ToastyService])],t)}();return e.Toasty=d,n.define=s,o.exports}),System.registerDynamic("src/toasty.component",["angular2/core","angular2/common"],!0,function(t,e,o){var n=this,s=n.define;n.define=void 0;var i=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},a=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},r=t("angular2/core"),c=t("angular2/common"),f=function(){function t(){this.closeToastEvent=new r.EventEmitter}return t.prototype.close=function(t){t.preventDefault(),this.closeToastEvent.next(this.toast)},i([r.Input(),a("design:type",Object)],t.prototype,"toast",void 0),i([r.Output("closeToast"),a("design:type",Object)],t.prototype,"closeToastEvent",void 0),t=i([r.Component({selector:"ng2-toast",directives:[c.CORE_DIRECTIVES],template:'\n
\n
\n
\n {{toast.title}}\n
\n {{toast.msg}}\n
\n
'}),a("design:paramtypes",[])],t)}();return e.Toast=f,n.define=s,o.exports}),System.registerDynamic("src/toasty.config",["angular2/core"],!0,function(t,e,o){var n=this,s=n.define;n.define=void 0;var i=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},a=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},r=t("angular2/core"),c=function(){function t(){this.limit=5,this.showClose=!0,this.position="bottom-right",this.timeout=5e3,this.theme="default"}return t=i([r.Injectable(),a("design:paramtypes",[])],t)}();return e.ToastyConfig=c,n.define=s,o.exports}),System.registerDynamic("src/toasty.service",["angular2/core","angular2/src/facade/lang","rxjs/Observable","./toasty.config"],!0,function(t,e,o){var n=this,s=n.define;n.define=void 0;var i=this&&this.__decorate||function(t,e,o,n){var s,i=arguments.length,a=3>i?e:null===n?n=Object.getOwnPropertyDescriptor(e,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,o,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(3>i?s(a):i>3?s(e,o,a):s(e,o))||a);return i>3&&a&&Object.defineProperty(e,o,a),a},a=this&&this.__metadata||function(t,e){return"object"==typeof Reflect&&"function"==typeof Reflect.metadata?Reflect.metadata(t,e):void 0},r=t("angular2/core"),c=t("angular2/src/facade/lang"),f=t("rxjs/Observable"),l=t("./toasty.config"),u=function(){function t(t){var e=this;this.config=t,this.uniqueCounter=0,this.toastsObservable=new f.Observable(function(t){e.toastsSubscriber=t}),this.clearObservable=new f.Observable(function(t){e.clearSubscriber=t})}return t.prototype.getToasts=function(){return this.toastsObservable},t.prototype.getClear=function(){return this.clearObservable},t.prototype["default"]=function(t){this.add(t,"default")},t.prototype.info=function(t){this.add(t,"info")},t.prototype.success=function(t){this.add(t,"success")},t.prototype.wait=function(t){this.add(t,"wait")},t.prototype.error=function(t){this.add(t,"error")},t.prototype.warning=function(t){this.add(t,"warning")},t.prototype.add=function(e,o){var n;if(n=c.isString(e)&&""!==e||c.isNumber(e)?{title:e.toString()}:e,!n||!n.title&&!n.msg)throw new Error("ng2-toasty: No toast title or message specified!");o=o||"default",this.uniqueCounter++;var s,i=this._checkConfigItem(this.config,n,"showClose");s=n.theme&&t.THEMES.indexOf(n.theme)>-1?n.theme:this.config.theme;var a={id:this.uniqueCounter,title:n.title,msg:n.msg,showClose:i,type:"toasty-type-"+o,theme:"toasty-theme-"+s,onAdd:n.onAdd&&c.isFunction(n.onAdd)?n.onAdd:null,onRemove:n.onRemove&&c.isFunction(n.onRemove)?n.onRemove:null};n.timeout?a.timeout=n.timeout||this.config.timeout:a.timeout=null;try{this.toastsSubscriber.next(a),n.onAdd&&c.isFunction(n.onAdd)&&n.onAdd.call(this,a)}catch(r){console.log(r),console.log("!!! Suggestion: Seems you forget add into your html?")}},t.prototype.clearAll=function(){this.clearSubscriber.next()},t.prototype._checkConfigItem=function(t,e,o){return e[o]===!1?!1:e[o]?!0:t[o]},t.THEMES=["default","material","bootstrap"],t=i([r.Injectable(),a("design:paramtypes",[l.ToastyConfig])],t)}();return e.ToastyService=u,n.define=s,o.exports}),System.registerDynamic("ng2-toasty",["./src/toasty.container","./src/toasty.component","./src/toasty.config","./src/toasty.service"],!0,function(t,e,o){"use strict";function n(t){for(var o in t)e.hasOwnProperty(o)||(e[o]=t[o])}var s=this,i=s.define;s.define=void 0;var a=t("./src/toasty.container"),r=t("./src/toasty.component"),c=t("./src/toasty.config"),f=t("./src/toasty.service");return n(t("./src/toasty.container")),n(t("./src/toasty.component")),n(t("./src/toasty.config")),n(t("./src/toasty.service")),Object.defineProperty(e,"__esModule",{value:!0}),e["default"]={providers:[c.ToastyConfig,f.ToastyService],directives:[a.Toasty,r.Toast]},s.define=i,o.exports}); //# sourceMappingURL=bundles/ng2-toasty.min.js.map \ No newline at end of file diff --git a/package.json b/package.json index 5515984..f91dafc 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ "typings": "./ng2-toasty.d.ts", "homepage": "https://github.com/akserg/ng2-toasty", "devDependencies": { - "angular2": "~2.0.0-beta.13", + "angular2": "~2.0.0-beta.14", "es6-promise": "~3.1.2", "es6-shim": "~0.35.0", "reflect-metadata": "0.1.2",