parent
7a6bdef334
commit
5376f1ba7b
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -0,0 +1,29 @@ |
||||
var notify = (function () { |
||||
var nt = {}; |
||||
var sel = '#notif'; |
||||
|
||||
nt.show = function (message, timeout) { |
||||
$(sel).html(message); |
||||
modal.show(sel); |
||||
|
||||
if (!_.isUndefined(timeout)) { |
||||
setTimeout(nt.hide, timeout); |
||||
} |
||||
}; |
||||
|
||||
nt.hide = function () { |
||||
var $m = $(sel); |
||||
$m.removeClass('visible'); |
||||
setTimeout(function () { |
||||
$m.addClass('hidden'); |
||||
}, 250); // transition time
|
||||
}; |
||||
|
||||
nt.init = function() { |
||||
$(sel).on('click', function() { |
||||
nt.hide(this); |
||||
}); |
||||
}; |
||||
|
||||
return nt; |
||||
})(); |
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in new issue