pandora/static/js/folderPlaceholder.js

22 lines
614 B
JavaScript
Raw Normal View History

'use strict';
2018-06-19 06:33:26 +00:00
pandora.ui.folderPlaceholder = function(id, section) {
var that = Ox.Element()
.addClass('OxLight')
.css({
height: '14px',
padding: '1px 4px',
2016-10-04 22:00:03 +00:00
}),
folderItems = pandora.getFolderItems(section);
that.updateText = function(string, isFind) {
return that.html(
2014-02-14 15:23:59 +00:00
string != 'volumes'
? Ox._('No {0} {1}' + (isFind ? ' found' : ''),
2016-10-04 22:00:03 +00:00
[Ox._(string), Ox._(folderItems.toLowerCase())])
2014-02-14 15:23:59 +00:00
: Ox._('No local volumes')
);
};
return that.updateText(id);
};