h5ai/src/_h5ai/public/js/lib/view/notification.js
2016-06-03 22:40:05 +02:00

17 lines
343 B
JavaScript

const {jq} = require('../globals');
const root = require('./root');
const $el = jq('<div id="notification"/>').hide().appendTo(root.$el);
function set(content) {
if (content) {
$el.stop(true, true).html(content).fadeIn(400);
} else {
$el.stop(true, true).fadeOut(400);
}
}
module.exports = {
$el,
set
};