Issue #2067323 by geerlingguy, jessebeach: Fixed Don't show empty vertical tabs area if all vertical tabs are hidden.
parent
358de91aee
commit
dda8d4d3f9
|
@ -148,6 +148,8 @@ Drupal.verticalTab.prototype = {
|
||||||
tabShow: function () {
|
tabShow: function () {
|
||||||
// Display the tab.
|
// Display the tab.
|
||||||
this.item.show();
|
this.item.show();
|
||||||
|
// Show the vertical tabs.
|
||||||
|
this.item.closest('.form-type-vertical-tabs').show();
|
||||||
// Update .first marker for items. We need recurse from parent to retain the
|
// Update .first marker for items. We need recurse from parent to retain the
|
||||||
// actual DOM element order as jQuery implements sortOrder, but not as public
|
// actual DOM element order as jQuery implements sortOrder, but not as public
|
||||||
// method.
|
// method.
|
||||||
|
@ -178,6 +180,10 @@ Drupal.verticalTab.prototype = {
|
||||||
if ($firstTab.length) {
|
if ($firstTab.length) {
|
||||||
$firstTab.data('verticalTab').focus();
|
$firstTab.data('verticalTab').focus();
|
||||||
}
|
}
|
||||||
|
// Hide the vertical tabs (if no tabs remain).
|
||||||
|
else {
|
||||||
|
this.item.closest('.form-type-vertical-tabs').hide();
|
||||||
|
}
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue