Fix findPreviousVisibleTab action

Fixes #3320
This commit is contained in:
Nick O'Leary 2022-01-03 21:19:48 +00:00
parent 91cb6ba73b
commit cf19d7f3ad
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 3 additions and 3 deletions

View File

@ -578,7 +578,7 @@ RED.tabs = (function() {
function findPreviousVisibleTab(li) {
if (!li) {
li = ul.find("li.active").parent();
li = ul.find("li.active");
}
var previous = li.prev();
while(previous.length > 0 && previous.hasClass("hide-tab")) {
@ -588,9 +588,9 @@ RED.tabs = (function() {
}
function findNextVisibleTab(li) {
if (!li) {
li = ul.find("li.active").parent();
li = ul.find("li.active");
}
var next = ul.find("li.active").next();
var next = li.next();
while(next.length > 0 && next.hasClass("hide-tab")) {
next = next.next();
}