Questions tagged [angular-toastr]

Angular-toastr is an open-source Angular port of CodeSeven's toastr library.

Angular-toastr is an open-source Angular port of CodeSeven's toastr library.

58 questions
7
votes
3 answers

How can I clear previous toastr before showing the new one and set a timeout between them?

I am using Angular toastr and I am stuck at passing a delay between hiding the previous toastr and showing the next one. There should be only one toastr at a time. I am hiding and showing it, but there is no visual difference, and still the toast…
Petya Naumova
  • 727
  • 2
  • 11
  • 23
6
votes
5 answers

How to change icon filling color in toastr

I have toastr success and error messages shown in my application. I changes the colors of the background and the font color. I want to change the icon colors shown in the messages. I have searched everywhere for this but I can't find a way to change…
shamila
  • 1,280
  • 6
  • 20
  • 45
4
votes
2 answers

ngx-toastr ToastrService.show() type parameter Angular 2 +

I can use ToastrService.success/error/warning/info() without problem, but when i use ToastrService.show() i don't know which correct string type i should send i tried send a enum like this: export enum ToastType { Success = 'success', …
AndresSp
  • 176
  • 3
  • 16
4
votes
3 answers

Original Toastr with Angular 5?

I like the original toastr b/c I could pop up a "Item X Saved" message and it stays on the page for X milliseconds after I redirect back to the home page. So I would like to use the original toastr library with Angular 5 and can't figure it out. Is…
user441058
  • 1,188
  • 1
  • 16
  • 32
3
votes
1 answer

ngx-toastr GlobalConfig timeout settings

Not able to achieve using the IndividualConfig and GlobalConfig classes. imports: [ToastrModule.forRoot({timeOut: 10000, positionClass: 'toast-bottom-right', preventDuplicates: true})] Setting the GlobalConfig like the above code snippet will set…
Chandrababu
  • 61
  • 2
  • 9
3
votes
2 answers

Set options for single instance of an Angular Toastr?

I am using Angular JS 1.4.1 and Angular Toastr 1.7.0. Most of the toastrs in my app are the default top right, and work fine. However, I want to call ONE with the positionClass: 'toast-top-full-width' and I can't get it to work. It still opens at…
Steve
  • 14,401
  • 35
  • 125
  • 230
3
votes
0 answers

removing duplicate message in ng2-toastr module

I am using ng2-toastr module, how to set preventduplicate property to true i.e I dont want to display same message multiple times. Can you explain how to make this?
Sharmile Murugaraj
  • 1,044
  • 1
  • 8
  • 10
2
votes
1 answer

How to run unit test case for toast message in angular service?

I am working with an app based on Angular 12. I have service called notification service which handles toast messages from ngx-toastr library. This is how that service looks like: export class NotificationService { constructor(private toastr:…
2
votes
1 answer

Using ng6-toastr-notification get error "No provider for ToasterComponent"

I am using angular 7 and installing an ng6-toastr-notifications app from this link I added as much of this code as allowed. This is my abridged app.module.ts file: import {BrowserAnimationsModule} from '@angular/platform-browser/animations' import…
Lee9287
  • 367
  • 3
  • 6
  • 18
2
votes
1 answer

Angular5-Toaster Dynamic component inject parameters

Good afternoon, I am trying to create a dynamic template to display information from a dynamic component as listed in the NPM readme. https://www.npmjs.com/package/angular5-toaster Example : import {BodyOutputType} from…
user1403598
  • 485
  • 1
  • 6
  • 21
2
votes
1 answer

Angular JS cascade notifications

I need your advice to help me. I'm making an Angular JS app and I need some notifications like angular-toastr or angular-ui-notification but showing not like a list but cascade. Like in picture bellow. Can anybody help with advice or realization…
hofshteyn
  • 1,272
  • 4
  • 16
  • 33
2
votes
3 answers

ng2-toastr not working in angular 2

I am trying to use ng2-toastr in my angular 2 app. I have followed all the instructions but the toastr fails to show up without any console error. I have also read somewhere that ng-toastr no longer works with angular 2 but have not found any valid…
waleed ali
  • 1,175
  • 10
  • 23
2
votes
2 answers

angular-toastr preventOpenDuplicates is not working

I am using angular-toastr and trying to prevent duplicate toastr by using toastr option preventOpenDuplicates, but might be its not working or may be I am doing something wrong. plunkr to reproduce issue toastr : toastr.error('test', 'open…
gaurav bhavsar
  • 2,033
  • 2
  • 22
  • 36
2
votes
4 answers

Find and clear a toast (Toastr)

I have a page where there may be multiple toasts added dynamically using the plugin https://github.com/CodeSeven/toastr. I have a link(Ok) on each toast on clicking that link I need to close only the particular toast not all toast that are visible.…
Gokul
  • 3,101
  • 4
  • 27
  • 45
1
vote
0 answers

Auth guard - angular - toastr service is not working

export class AuthGuard implements CanActivate { constructor(private accountService:AccountService, private toastr:ToastrService){} canActivate(): Observable { return this.accountService.currentUser$.pipe( map(user => { …
Zyad Tarek
  • 21
  • 1
  • 2
1
2 3 4