New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
navbarPage with title and head tag causes a ghost tab to appear #827
Comments
For anyone who has this problem, here is my hacky fix. The first line in the server tells the first tab to be selected, and I'm adding a CSS that makes the ghost tab not appear. WATCH OUT because if you use this hack and the problem is fixed in a later shiny version, you will have to remember to remove the css hack, or else your first real tab will not appear.
|
Why not just put the runApp(list(
ui = tagList(
tags$head(tags$style(HTML("body{ background: red; }"))),
navbarPage(
"Title",
tabPanel(title = "First"),
tabPanel(title = "Second")
)
),
server = function(input, output, session) {}
)) |
Thanks Joe |
- Known bug: rstudio/shiny#827 - Also added nav buttons to PCA page.
Previous short discussion: https://groups.google.com/forum/#!topic/shiny-discuss/6C9SbSLbKmc
It seems that if I use
navbarPage
with a title and try to add anything to the head tag viatags$head(...)
, an erroneous tab appears before the first tab and it's the selected tab so it's very annoying. I'm currently getting around that by programatically setting the next tab as selected and using CSS to hide to fake tab, but a fix would be nice.Example:
Using shiny
0.11.1.9003
The text was updated successfully, but these errors were encountered: