'Notification position in 'Asp.net. Boilerplate'
Is there any possibility to change the window display location of soft notification abp.notify.warn?
Can we adjust the display window x y in abp.notify.warn() soft notification?
abp.notify.warn(app.localize('EmployeeNotFound'));
Solution 1:[1]
It's toastr plugin. The implementation is done in abp.toastr.js. Write the code below to configure position.
toastr.options.positionClass = 'toast-top-right';
Solution 2:[2]
I think you will need to implement custom CSS to achieve your goals targeting the sweet-alert css class.
You should take a look at the SweetAlert documentation. Every abp popup uses this plugin.
Solution 3:[3]
The notification use toastr plugin to display message, you can refer to toastr demo here. And change something that you want in abp.toastr.js file
Solution 4:[4]
You can modify in this file in the latest version of ABP:
abp.notify.js
Solution 5:[5]
Actually the abp.notify.warn allows passing an options parameter. So that you can easily specify the exact X,Y position for the notification box.
This is the method signature:
NotifyService.warn(message: string, title?: string, options?: any): void
Accordingly, you can adjust the display window x,y Like this:
abp.notify.warn(app.localize('EmployeeNotFound'), '', {
"position": "55,150"
});
There is a set of predefined positions if you like to use too:
'top', 'top-start', 'top-end', 'center', 'center-start', 'center-end', 'bottom', 'bottom-start', or 'bottom-end'
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Alper Ebicoglu |
| Solution 2 | Gabriel Robert |
| Solution 3 | tiennguyen |
| Solution 4 | Sani |
| Solution 5 | Rami Assi |

