Snackbar fix message color #204. CR: Juan
This commit is contained in:
parent
da45353777
commit
e7f258061c
|
@ -22,6 +22,11 @@ export default class Controller extends Component {
|
||||||
* @param {Object} data The message data
|
* @param {Object} data The message data
|
||||||
*/
|
*/
|
||||||
show(data) {
|
show(data) {
|
||||||
|
if (this.shown) {
|
||||||
|
this.hide();
|
||||||
|
this.onTransitionEnd();
|
||||||
|
}
|
||||||
|
|
||||||
this.clearTimeouts();
|
this.clearTimeouts();
|
||||||
this.shown = true;
|
this.shown = true;
|
||||||
this.textNode.textContent = data.message;
|
this.textNode.textContent = data.message;
|
||||||
|
@ -43,8 +48,8 @@ export default class Controller extends Component {
|
||||||
* @param {Object} data The message data
|
* @param {Object} data The message data
|
||||||
*/
|
*/
|
||||||
showError(data) {
|
showError(data) {
|
||||||
this.$snackbar.addClass('error');
|
|
||||||
this.show(data);
|
this.show(data);
|
||||||
|
this.$snackbar.addClass('error');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue