taskbar text incase <script> is title

v1.18.x
barisusakli 11 years ago
parent 4fa79dc821
commit 3f9fa0137c

@ -60,11 +60,12 @@ define('taskbar', function() {
var element = taskbar.tasklist.find('li[data-uuid="'+uuid+'"]'); var element = taskbar.tasklist.find('li[data-uuid="'+uuid+'"]');
if(element.length) if(element.length)
return; return;
var title = $('<div></div>').html(options.title || 'NodeBB Task').text();
var btnEl = $('<li />') var btnEl = $('<li />')
.html('<a href="#">' + .html('<a href="#">' +
(options.icon ? '<img src="' + options.icon + '" />' : '') + (options.icon ? '<img src="' + options.icon + '" />' : '') +
'<span>' + (options.title || 'NodeBB Task') + '</span>' + '<span>' + title + '</span>' +
'</a>') '</a>')
.attr({ .attr({
'data-module': module, 'data-module': module,

Loading…
Cancel
Save