debian-mirror-gitlab/app/assets/javascripts/flash.js.coffee

13 lines
253 B
CoffeeScript
Raw Normal View History

2015-04-26 12:48:37 +05:30
class @Flash
2014-09-02 18:07:02 +05:30
constructor: (message, type)->
flash = $(".flash-container")
flash.html("")
$('<div/>',
class: "flash-#{type}",
text: message
).appendTo(".flash-container")
flash.click -> $(@).fadeOut()
flash.show()