contextMenu.js
function processItem(params) {
          var nestedMenu = extractNestedMenu(params);

          // if html property is not defined, fallback to text, otherwise use default text
          // if first item in the item array is a function then invoke .call()
          // if first item is a string, then text should be the string.

          var text = DEFAULT_ITEM_TEXT;
          var currItemParam = angular.extend({}, params);
          var item = params.item;
          var enabled = item.enabled === undefined ? item[2] : item.enabled;

          currItemParam.nestedMenu = nestedMenu;
          currItemParam.enabled = resolveBoolOrFunc(enabled, params);
          currItemParam.text = createAndAddOptionText(currItemParam);

          registerCurrentItemEvents(currItemParam);

        }
function processItem(params) {
          var nestedMenu = extractNestedMenu(params);

          // if html property is not defined, fallback to text, otherwise use default text
          // if first item in the item array is a function then invoke .call()
          // if first item is a string, then text should be the string.

          var text = DEFAULT_ITEM_TEXT;
          var currItemParam = angular.extend({}, params);
          var item = params.item;
          var enabled = item.enabled === undefined ? item[2] : item.enabled;

          currItemParam.nestedMenu = nestedMenu;
          currItemParam.enabled = resolveBoolOrFunc(enabled, params);
          currItemParam.text = createAndAddOptionText(currItemParam);

          registerCurrentItemEvents(currItemParam);

        }
function processItem ( params ) { var nestedMenu = extractNestedMenu ( params ) ; // if html property is not defined, fallback to text, otherwise use default text // if first item in the item array is a function then invoke .call() // if first item is a string, then text should be the string. var text = DEFAULT_ITEM_TEXT ; var currItemParam = angular . extend ( { } , params ) ; var item = params . item ; var enabled = item . enabled === undefined ? item [ 2 ] : item . enabled ; currItemParam . nestedMenu = nestedMenu ; currItemParam . enabled = resolveBoolOrFunc ( enabled , params ) ; currItemParam . text = createAndAddOptionText ( currItemParam ) ; registerCurrentItemEvents ( currItemParam ) ; }
Process each individual item

Properties of params:
- $scope
- event
- modelValue
- level
- item
- $ul
- $li
- $promises
Process each individual item