Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
SendComponent.prototype.showToast = function (type, title, body) {
this.config = new angular2_toaster_1.ToasterConfig({
positionClass: 'toast-top-right',
timeout: 10000,
newestOnTop: true,
tapToDismiss: true,
preventDuplicates: false,
animation: 'slideDown',
limit: 1,
});
var toast = {
type: type,
title: title,
body: body,
timeout: 10000,
showCloseButton: true,
bodyOutputType: angular2_toaster_1.BodyOutputType.TrustedHtml,
};
info (title: string, body: string, params?: any) {
this.config = new ToasterConfig({
positionClass: params && params.position?params.position:this.positions,
timeout: params && params.timeout?params.timeout:this.timeout,
newestOnTop: params && params.isNewestOnTop?params.isNewestOnTop:this.isNewestOnTop,
tapToDismiss: params && params.isHideOnClick?params.isHideOnClick:this.isHideOnClick,
preventDuplicates: params && params.isDuplicatesPrevented?params.isDuplicatesPrevented:this.isDuplicatesPrevented,
animation: params && params.animationType?params.animationType:this.animationType,
limit: params && params.toastsLimit?params.toastsLimit:this.toastsLimit,
});
const toast: Toast = {
type: 'info',
title: title,
body: body,
timeout: params && params.timeout?params.timeout:this.timeout,
showCloseButton: params && params.isCloseButton?params.isCloseButton:this.isCloseButton,
bodyOutputType: BodyOutputType.TrustedHtml,
};
private showToast(type: string, title: string, body: string) {
this.config = new ToasterConfig({
positionClass: 'toast-top-right',
timeout: 10000,
newestOnTop: true,
tapToDismiss: true,
preventDuplicates: false,
animation: 'slideDown',
limit: 1,
});
const toast: Toast = {
type: type,
title: title,
body: body,
timeout: 10000,
showCloseButton: true,
bodyOutputType: BodyOutputType.TrustedHtml,
};
private showToast(type: string, title: string, body: string) {
this.config = new ToasterConfig({
positionClass: 'toast-top-right',
timeout: 10000,
newestOnTop: true,
tapToDismiss: true,
preventDuplicates: false,
animation: 'slideDown',
limit: 1,
});
const toast: Toast = {
type: type,
title: title,
body: body,
timeout: 10000,
showCloseButton: true,
bodyOutputType: BodyOutputType.TrustedHtml,
};
private showToast(type: string, title: string, body: string) {
this.config = new ToasterConfig({
positionClass: 'toast-top-right',
timeout: 10000,
newestOnTop: true,
tapToDismiss: true,
preventDuplicates: false,
animation: 'slideDown',
limit: 1,
});
const toast: Toast = {
type: type,
title: title,
body: body,
timeout: 10000,
showCloseButton: true,
bodyOutputType: BodyOutputType.TrustedHtml,
};
DappComponent.prototype.showToast = function (type, title, body) {
this.config = new angular2_toaster_1.ToasterConfig({
positionClass: 'toast-top-right',
timeout: 10000,
newestOnTop: true,
tapToDismiss: true,
preventDuplicates: false,
animation: 'slideDown',
limit: 1,
});
var toast = {
type: type,
title: title,
body: body,
timeout: 10000,
showCloseButton: true,
bodyOutputType: angular2_toaster_1.BodyOutputType.TrustedHtml,
};
private showToast(type: string, title: string, body: string) {
this.config = new ToasterConfig({
positionClass: 'toast-top-right',
timeout: 10000,
newestOnTop: true,
tapToDismiss: true,
preventDuplicates: false,
animation: 'slideDown',
limit: 1,
});
const toast: Toast = {
type: type,
title: title,
body: body,
timeout: 10000,
showCloseButton: true,
bodyOutputType: BodyOutputType.TrustedHtml,
};
warning (title: string, body: string, params?: any) {
this.config = new ToasterConfig({
positionClass: params && params.position?params.position:this.positions,
timeout: params && params.timeout?params.timeout:this.timeout,
newestOnTop: params && params.isNewestOnTop?params.isNewestOnTop:this.isNewestOnTop,
tapToDismiss: params && params.isHideOnClick?params.isHideOnClick:this.isHideOnClick,
preventDuplicates: params && params.isDuplicatesPrevented?params.isDuplicatesPrevented:this.isDuplicatesPrevented,
animation: params && params.animationType?params.animationType:this.animationType,
limit: params && params.toastsLimit?params.toastsLimit:this.toastsLimit,
});
const toast: Toast = {
type: 'warning',
title: title,
body: body,
timeout: params && params.timeout?params.timeout:this.timeout,
showCloseButton: params && params.isCloseButton?params.isCloseButton:this.isCloseButton,
bodyOutputType: BodyOutputType.TrustedHtml,
};