ui.bootstrap.contextMenu
ui.bootstrap.contextMenu copied to clipboard
Allow icons (as HTML) in menu item.
This way one can use icons in the menu elements like
$scope.menuOptions = function(program) {
return [
[function() {return '<i class="fa fa-fw fa-pencil"></i> edit'},
function ($itemScope) { console.log('edit') } ],
];
};
If this shouldn't be the default I'd suggest a 4th parameter to each element containing options, to be open for future extensions:
$scope.menuOptions = function(program) {
return [
[function() {return '<i class="fa fa-fw fa-pencil"></i> edit'},
function ($itemScope) { console.log('edit') },
true,
{allowHtml: true}
],
];
};
I am working on a huge addition at the moment and a feature related to this will be on it.