Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified R/sysdata.rda
Binary file not shown.
7 changes: 6 additions & 1 deletion inst/bs3compat/js/bs3compat.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,12 @@ $(function() {
var SELECTOR = '[data-toggle="tab"], [data-toggle="pill"], [data-bs-toggle="tab"], [data-bs-toggle="pill"]';
$(document).on(EVENT_KEY, SELECTOR, function(event) {
event.preventDefault();
$(this).tab("show");
var $this = $(this);
// New (bs5+) tabs use only `data-bs-toggle`, so we provide fallback manually
if (!$this.attr("data-bs-toggle") && $this.attr("data-toggle")) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The bs namespace is actually configurable, and may change in a future, so let's see if there's a CSS variables we can read to get the actual namespace.

$this.attr("data-bs-toggle", $this.attr("data-toggle"));
}
$this.tab("show");
});

function TabPlugin(config) {
Expand Down