AngularJS 烤面包机个人吐司位置
AngularJS toaster individual toast position
我已经在 html
中全局配置了 toasts
<toaster-container toaster-options="{'close-button': true, 'position-class': 'toast-bottom-right'}"></toaster-container>
这是我弹出它们的方式
core.toaster.pop({
type: 'info',
title: 'some title',
timeout: 0
});
我想知道如何单独定位每个 toast 并覆盖 html 的全局配置。默认情况下,它们位于右下角,但例如我希望在右上角显示一个祝酒词。在 toaster.pop 中添加类似 positionClass: 'toast-top-right' 的内容不起作用。
试试这个,
您可以为您的烤面包机创建另一个烤面包机容器,您需要使用 toaster_id 将其定位在不同的位置。
请参阅此 plunker 工作模型。
希望,这个会有所帮助...
我已经在 html
中全局配置了 toasts<toaster-container toaster-options="{'close-button': true, 'position-class': 'toast-bottom-right'}"></toaster-container>
这是我弹出它们的方式
core.toaster.pop({
type: 'info',
title: 'some title',
timeout: 0
});
我想知道如何单独定位每个 toast 并覆盖 html 的全局配置。默认情况下,它们位于右下角,但例如我希望在右上角显示一个祝酒词。在 toaster.pop 中添加类似 positionClass: 'toast-top-right' 的内容不起作用。
试试这个,
您可以为您的烤面包机创建另一个烤面包机容器,您需要使用 toaster_id 将其定位在不同的位置。
请参阅此 plunker 工作模型。
希望,这个会有所帮助...