Skip to content

Commit

Permalink
tests(tabPanel): Update for latest bslib
Browse files Browse the repository at this point in the history
  • Loading branch information
gadenbuie committed Nov 29, 2023
1 parent dbbe7f9 commit 1240223
Showing 1 changed file with 70 additions and 66 deletions.
136 changes: 70 additions & 66 deletions tests/testthat/_snaps/tabPanel.md
Original file line number Diff line number Diff line change
Expand Up @@ -182,84 +182,88 @@
Code
nav_page
Output
<nav class="navbar navbar-default navbar-static-top" role="navigation">
<body class="bslib-page-navbar">
<nav class="navbar navbar-default navbar-static-top" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<span class="navbar-brand">Title</span>
</div>
<ul class="nav navbar-nav nav-underline" data-tabsetid="4785">
<li class="active">
<a href="#tab-4785-1" data-toggle="tab" data-bs-toggle="tab" data-value="A">A</a>
</li>
<li>
<a href="#tab-4785-2" data-toggle="tab" data-bs-toggle="tab" data-value="B">
<i aria-label="github icon" class="fab fa-github fa-fw" role="presentation"></i>
B
</a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" data-bs-toggle="dropdown" data-value="Menu">
Menu
<b class="caret"></b>
</a>
<ul class="dropdown-menu" data-tabsetid="1502">
<li>
<a href="#tab-1502-1" data-toggle="tab" data-bs-toggle="tab" data-value="C">C</a>
</li>
</ul>
</li>
</ul>
</div>
</nav>
<div class="container-fluid">
<div class="navbar-header">
<span class="navbar-brand">Title</span>
<div class="tab-content" data-tabsetid="4785">
<div class="tab-pane active" data-value="A" id="tab-4785-1">a</div>
<div class="tab-pane" data-value="B" data-icon-class="fab fa-github fa-fw" id="tab-4785-2">b</div>
<div class="tab-pane" data-value="C" id="tab-1502-1">c</div>
</div>
<ul class="nav navbar-nav" data-tabsetid="4785">
<li class="active">
<a href="#tab-4785-1" data-toggle="tab" data-bs-toggle="tab" data-value="A">A</a>
</li>
<li>
<a href="#tab-4785-2" data-toggle="tab" data-bs-toggle="tab" data-value="B">
<i aria-label="github icon" class="fab fa-github fa-fw" role="presentation"></i>
B
</a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" data-bs-toggle="dropdown" data-value="Menu">
Menu
<b class="caret"></b>
</a>
<ul class="dropdown-menu" data-tabsetid="1502">
<li>
<a href="#tab-1502-1" data-toggle="tab" data-bs-toggle="tab" data-value="C">C</a>
</li>
</ul>
</li>
</ul>
</div>
</nav>
<div class="container-fluid">
<div class="tab-content" data-tabsetid="4785">
<div class="tab-pane active" data-value="A" id="tab-4785-1">a</div>
<div class="tab-pane" data-value="B" data-icon-class="fab fa-github fa-fw" id="tab-4785-2">b</div>
<div class="tab-pane" data-value="C" id="tab-1502-1">c</div>
</div>
</div>
</body>

---

Code
bslib_tags(x)
Output
<nav class="navbar navbar-default navbar-static-top" role="navigation">
<body class="bslib-page-navbar">
<nav class="navbar navbar-default navbar-static-top" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<span class="navbar-brand">Title</span>
</div>
<ul class="nav navbar-nav nav-underline" data-tabsetid="4785">
<li class="nav-item">
<a href="#tab-4785-1" data-toggle="tab" data-bs-toggle="tab" data-value="A" class="nav-link active">A</a>
</li>
<li class="nav-item">
<a href="#tab-4785-2" data-toggle="tab" data-bs-toggle="tab" data-value="B" class="nav-link">
<i aria-label="github icon" class="fab fa-github fa-fw" role="presentation"></i>
B
</a>
</li>
<li class="dropdown nav-item">
<a href="#" class="dropdown-toggle nav-link" data-toggle="dropdown" data-bs-toggle="dropdown" data-value="Menu">
Menu
<b class="caret"></b>
</a>
<ul class="dropdown-menu" data-tabsetid="1502">
<li>
<a href="#tab-1502-1" data-toggle="tab" data-bs-toggle="tab" data-value="C" class="dropdown-item">C</a>
</li>
</ul>
</li>
</ul>
</div>
</nav>
<div class="container-fluid">
<div class="navbar-header">
<span class="navbar-brand">Title</span>
<div class="tab-content" data-tabsetid="4785">
<div class="tab-pane active" data-value="A" id="tab-4785-1">a</div>
<div class="tab-pane" data-value="B" data-icon-class="fab fa-github fa-fw" id="tab-4785-2">b</div>
<div class="tab-pane" data-value="C" id="tab-1502-1">c</div>
</div>
<ul class="nav navbar-nav" data-tabsetid="4785">
<li class="nav-item">
<a href="#tab-4785-1" data-toggle="tab" data-bs-toggle="tab" data-value="A" class="nav-link active">A</a>
</li>
<li class="nav-item">
<a href="#tab-4785-2" data-toggle="tab" data-bs-toggle="tab" data-value="B" class="nav-link">
<i aria-label="github icon" class="fab fa-github fa-fw" role="presentation"></i>
B
</a>
</li>
<li class="dropdown nav-item">
<a href="#" class="dropdown-toggle nav-link" data-toggle="dropdown" data-bs-toggle="dropdown" data-value="Menu">
Menu
<b class="caret"></b>
</a>
<ul class="dropdown-menu" data-tabsetid="1502">
<li>
<a href="#tab-1502-1" data-toggle="tab" data-bs-toggle="tab" data-value="C" class="dropdown-item">C</a>
</li>
</ul>
</li>
</ul>
</div>
</nav>
<div class="container-fluid">
<div class="tab-content" data-tabsetid="4785">
<div class="tab-pane active" data-value="A" id="tab-4785-1">a</div>
<div class="tab-pane" data-value="B" data-icon-class="fab fa-github fa-fw" id="tab-4785-2">b</div>
<div class="tab-pane" data-value="C" id="tab-1502-1">c</div>
</div>
</div>
</body>

# String input is handled properly

Expand Down

0 comments on commit 1240223

Please sign in to comment.