% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/paintr-app-bslib.R
\name{ptr_app_bslib}
\alias{ptr_app_bslib}
\title{Bslib-Themed App: A Demonstration Wrapper}
\usage{
ptr_app_bslib(
  formula,
  envir = parent.frame(),
  ui_text = NULL,
  expr_check = TRUE,
  safe_to_remove = character(),
  theme = NULL,
  spec = NULL
)
}
\arguments{
\item{formula}{A single formula string using \code{ggpaintr} placeholders.}

\item{envir}{Environment used to resolve local data objects when building
the app.}

\item{ui_text}{Optional named list of copy overrides for UI labels, helper
text, and placeholders. The app title is read from
\code{ui_text$shell$title$label}; defaults to \code{"ggpaintr"}.}

\item{expr_check}{Controls formula-level \code{ppExpr} validation: \code{TRUE}
(default) applies the built-in denylist + AST walker; \code{FALSE} disables
formula-level validation; a \code{list} with \code{deny_list}/\code{allow_list} entries
customises the formula-level policy. Runtime-typed \code{ppExpr} input is
always screened against the built-in denylist regardless. See the
safety chapter of the ggpaintr book (development-version docs):
\url{https://willju-wangqian.github.io/ggpaintr-book/safety.html}.}

\item{safe_to_remove}{Character vector of additional function names whose
zero-argument calls should be dropped after placeholder substitution
leaves them empty. Defaults to \code{character()}.}

\item{theme}{A \code{bslib} theme object. Defaults to a Bootstrap 5 Flatly
bootswatch. Pass any \code{\link[bslib:bs_theme]{bslib::bs_theme()}} result to customize. This is a
\code{bslib} passthrough and is not part of the ggpaintr public surface the
wrapper demonstrates — wrappers are free to expose downstream-library
args like this in addition to whatever ggpaintr primitives they compose.}

\item{spec}{An optional named list of fully-qualified Shiny input id ->
value, used to override widget defaults at session boot.

For the formula grammar (placeholder keywords, shared annotation,
empty-call cleanup), see \code{\link[=ptr_app]{ptr_app()}}.}
}
\value{
A \code{shiny.appobj}.
}
\description{
A small wrapper that composes the public ggpaintr primitives
(\code{\link[=ptr_ui_controls]{ptr_ui_controls()}}, \code{\link[=ptr_ui_plot]{ptr_ui_plot()}}, \code{\link[=ptr_ui_toggle_code]{ptr_ui_toggle_code()}},
\code{\link[=ptr_server]{ptr_server()}}) inside a \code{\link[bslib:page_sidebar]{bslib::page_sidebar()}} shell. Exported
so users who want a quick
\code{bslib}-themed app can call it directly, but its primary purpose is to
illustrate the wrapper pattern: the
entire source is short enough to copy and adapt for any other layout or
theme.
}
\details{
For the recommended primary entry points, see \code{\link[=ptr_app]{ptr_app()}} and
\code{\link[=ptr_app_grid]{ptr_app_grid()}}. Requires the \code{bslib} package
(\code{install.packages("bslib")}).

Single-formula \code{ppVar(shared = "...")} coordination is not supported on this
wrapper — the auto-built shared widgets \code{ptr_app()} provides require an
internal helper that is not part of the public API today. Use \code{\link[=ptr_app]{ptr_app()}}
for that case, or \code{\link[=ptr_app_grid]{ptr_app_grid()}} for multi-formula shared coordination
(the shared widgets auto-render from each placeholder's own \code{build_ui}).
}
\keyword{internal}
