-
Notifications
You must be signed in to change notification settings - Fork 58
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
navbar compatibility #4
Conversation
Did you mean to check in a test app? |
There doesn't appear to be a dark-mode dropdown menu in bootstrap 4. This is what happens in straight bootstrap 4 if you change one of the examples from And also looking at the _dropdown.scss file in bootstrap, there only appears to be one set of colors. I'm not saying we shouldn't fix it, just that it may go into the category of "ways to make bootstrap 4 even better" rather than "ways to make bootstrap 3 work in bootstrap 4". |
- navbarList is now supported - navbarPage(position="fixed-bottom") dropdown menus now use poppler - added more test cases to test-apps/bs3-navs
5f09701
to
7642a23
Compare
Looking good thus far! Just FYI, we may want to consider a shim for |
@jcheng5 consider 17a5f23 experimental at this point (just want to see if you think this is viable thing to do) And now that I think of it, maybe this JS should live in rmarkdown and replace the existing |
This reverts commit 17a5f23.
… in the 2nd theme
For posterity, BS3 style content fading doesn't appear to work currently, but I'll approve and file an issue so we can get moving in the rmarkdown pull request library(bootscss)
library(htmltools)
browsable(withTags(body(
bs4_sass(),
ul(
class="nav nav-tabs", role="tablist",
li(
role="presentation", class="active",
a(
href="#home", "aria-controls" = "home", role="tab", "data-toggle"="tab",
"Home"
)
),
li(
role="presentation",
a(
href="#about", "aria-controls" = "about", role="tab", "data-toggle"="tab",
"About"
)
)
),
div(
class="tab-content",
div(
role="tabpanel", class="tab-pane fade in active", id="home",
"Foo"
),
div(role="tabpanel", class="tab-pane fade", id="about",
"Bar"
)
)
))) |
The purpose of this PR is to make it possible for bs3 navigation bar markup to work properly when bs4 is loaded on the page (without interfering with bs4 navigation bars, if they happen to be on the page also).
Testing notes
There's a test app under
test-apps/bs3-navs/app.R
. You can either check out the repo and navigate there, or just download the two files at https://github.com/rstudio/bootsass/tree/master/test-apps/bs3-navs into the same directory and run the app.R.bootstrap()
tobootstrap(theme = "cosmo")
) and ensure that the "bs3 navbarPage" section looks similar to the "bs4 navbar - default" section. Also that the "bs3 navbarPage (inverse)" section looks similar to the "bs4 navbar (dark)" sectionTODO
<li>
but not the<a>
, which causes a no-opnavbar-inverse
, drop-down menus have the wrong coloring (investigated and this problem exists in bs4 as well)$(nav_anchor).tab("show")
needs to work for both bs3 and bs4