Always set data-value attribute for .sidebarMenuSelectedTabItem #216
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #214: make sure that the
data-value
attribute of.sidebarMenuSelectedTabItem
is always set in the body of theensureActivatedTab()
function.Repro
See #214 or here is a more concise one (bug:
input$tabs
should start out with the value"tab1"
, but it starts out withNULL
and stays that way until you click on the other tab):Postemortem
This bug was hard to spot for a few reasons:
selected = TRUE
on any tab (the default). I.e. this has the right behavior:It disappears as soon as you move on to another tab.
It's orthogonal to the matching up of
menuItem
s andtabItem
s. I.e. this works works as expected, even thoughinput$tabs
starts out NULL as well: