dist/lumx.js
function togglePane(evt, parentIndex, indexOrKey, selectLeaf) {
            selectLeaf = (angular.isUndefined(selectLeaf)) ? true : selectLeaf;
            var pane = lxSelect.choicesViewSize === 'large' ? lxSelect.panes[parentIndex] : lxSelect.openedPanes[parentIndex];

            if (angular.isUndefined(pane)) {
                return;
            }

            var key = indexOrKey;
            if (angular.isObject(pane) && angular.isNumber(indexOrKey)) {
                key = (Object.keys(pane) || [])[indexOrKey];
            }

            if (angular.isDefined(toggledPanes[parentIndex])) {
                var previousKey = toggledPanes[parentIndex].key;

                _closePane(parentIndex);

                if (previousKey === key) {
                    return;
                }
            }

            var isLeaf = lxSelect.isLeaf(pane[key]);
            if (isLeaf) {
                if (selectLeaf) {
                    lxSelect.toggleChoice(pane[key], evt);
                }

                return;
            }

            _openPane(parentIndex, key, false);
        }
function togglePane(evt, parentIndex, indexOrKey, selectLeaf) {
            selectLeaf = (angular.isUndefined(selectLeaf)) ? true : selectLeaf;
            var pane = lxSelect.choicesViewSize === 'large' ? lxSelect.panes[parentIndex] : lxSelect.openedPanes[parentIndex];

            if (angular.isUndefined(pane)) {
                return;
            }

            var key = indexOrKey;
            if (angular.isObject(pane) && angular.isNumber(indexOrKey)) {
                key = (Object.keys(pane) || [])[indexOrKey];
            }

            if (angular.isDefined(toggledPanes[parentIndex])) {
                var previousKey = toggledPanes[parentIndex].key;

                _closePane(parentIndex);

                if (previousKey === key) {
                    return;
                }
            }

            var isLeaf = lxSelect.isLeaf(pane[key]);
            if (isLeaf) {
                if (selectLeaf) {
                    lxSelect.toggleChoice(pane[key], evt);
                }

                return;
            }

            _openPane(parentIndex, key, false);
        }
function togglePane ( evt , parentIndex , indexOrKey , selectLeaf ) { selectLeaf = ( angular . isUndefined ( selectLeaf ) ) ? true : selectLeaf ; var pane = lxSelect . choicesViewSize === 'large' ? lxSelect . panes [ parentIndex ] : lxSelect . openedPanes [ parentIndex ] ; if ( angular . isUndefined ( pane ) ) { return ; } var key = indexOrKey ; if ( angular . isObject ( pane ) && angular . isNumber ( indexOrKey ) ) { key = ( Object . keys ( pane ) || [ ] ) [ indexOrKey ] ; } if ( angular . isDefined ( toggledPanes [ parentIndex ] ) ) { var previousKey = toggledPanes [ parentIndex ] . key ; _closePane ( parentIndex ) ; if ( previousKey === key ) { return ; } } var isLeaf = lxSelect . isLeaf ( pane [ key ] ) ; if ( isLeaf ) { if ( selectLeaf ) { lxSelect . toggleChoice ( pane [ key ] , evt ) ; } return ; } _openPane ( parentIndex , key , false ) ; }
Toggle a pane.

@param {Event}         evt               The click event that led to toggle the pane.
@param {number}        parentIndex       The index of the containing pane.
@param {number|string} indexOrKey        The index or the name of the pane to toggle.
@param {boolean}       [selectLeaf=true] Indicates if we want to select the choice if the pane to toggle is
in fact a leaf.
Toggle a pane .