1 define(function(require) {
6 var $ = require('libs/jquery'),
7 template = require('libs/text!modules/statusBar/statusBar.html'),
8 logging = require('fnpjs/logging/logging');
10 var logger = logging.getLogger('statusBar');
12 return function(sandbox){
14 var view = $(template);
18 return sandbox.publish('ready');
23 showAction: function(action) {
24 var state = action.getState(),
25 description = state.description;
27 description = state.allowed ? gettext('Undescribed action') : gettext('Action not allowed');
28 logger.info('Undescribed action: ' + action.name);
30 view.text(description);
32 view.prepend('<span class="badge badge-warning" style="margin-right: 5px">!</span>');
35 clearAction: function() {