ESP8266 part of the f105-motor-demo project (see f105-motor-demo_stm32)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
490 B

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;
})();