in src/components/UncontrolledTabs.js [108:128]
function getPrevTab(index) {
let i = index;
// Look for non-disabled tab from index to first tab on the left
while (i--) {
if (!isTabDisabled(getTab(i))) {
return i;
}
}
// If no tab found, continue searching from last tab on right to index
i = getTabsCount();
while (i-- > index) {
if (!isTabDisabled(getTab(i))) {
return i;
}
}
// No tabs are disabled, return index
return index;
}