code: function firstVisibleChild() {
          for (var i = 0; i < openMenuNode.children.length; ++i) {
            if ($window.getComputedStyle(openMenuNode.children[i]).display != 'none') {
              return openMenuNode.children[i];
            }
          }
        }
docs: Gets the first visible child in the openMenuNode
  Necessary incase menu nodes are being dynamically hidden