rhodecode-toast.js
31 lines
| 623 B
| application/javascript
|
JavascriptLexer
r703 | Polymer({ | |||
is: 'rhodecode-toast', | ||||
properties: { | ||||
toasts: { | ||||
type: Array, | ||||
value: function(){ | ||||
return [] | ||||
} | ||||
} | ||||
}, | ||||
observers: [ | ||||
'_changedToasts(toasts.splices)' | ||||
], | ||||
ready: function(){ | ||||
}, | ||||
_changedToasts: function(newValue, oldValue){ | ||||
this.$['p-toast'].notifyResize(); | ||||
}, | ||||
dismissNotifications: function(){ | ||||
this.$['p-toast'].close(); | ||||
r778 | }, | |||
handleClosed: function(){ | ||||
r703 | this.splice('toasts', 0); | |||
}, | ||||
open: function(){ | ||||
this.$['p-toast'].open(); | ||||
}, | ||||
_gettext: _gettext | ||||
}); | ||||