rstudio / rstudio/bslib

Bootstrap navbar variables not working in bslib 0.6.1 but working in 0.5

Open
#978 0 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
SCSS
Stars
569
Forks
72
Avg merge
1d 2h
Merged PRs (30d)
5

Description

@gadenbuie and @cpsievert asked me to report this bug so I'm not following the guidelines :)

I'm finding that the bootstrap 5 navbar variables are not working for me using bslib version 0.6.1.

Note that the bootstrap variable body-bg works in both versions.

# This shows a red nav bar in bslib 0.5 but not in 0.6.1
library(shiny)
library(bslib)

ui <- page_navbar(
  theme = bs_theme(version = 5, "navbar-bg" = "red"),
  title = "My App",
  nav_panel(title = "One", p("First page content.")),
)

server <- function(...) { }

shinyApp(ui, server)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the supplied Shiny example using bslib 0.6.1, then compare its output with bslib 0.5 and the working body-bg variable. Trace how page_navbar() passes the Bootstrap 5 "navbar-bg" theme variable; done means the example renders a red navbar on 0.6.1 as it does on 0.5.

Written by the indexing model from the issue text.

Assessment

Tech stack
bootstrap, r
Domain
frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.