% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/paintr-app.R
\name{ptr_ui_code}
\alias{ptr_ui_code}
\title{Generated-Code Pane Piece for a \code{ggpaintr} Formula}
\usage{
ptr_ui_code(id = NULL, style = c("panel", "window"))
}
\arguments{
\item{id}{Optional module id; the namespace prefix for the output.
Defaults to \code{NULL} (identity namespace). When set, must match the
\code{id} passed to the other piece functions and the server wiring.}

\item{style}{\code{"panel"} (default) renders a plain, always-visible code
card suitable for free placement. \code{"window"} renders the draggable
slide-out window (with Copy / Close) used by the bundled apps; it is
hidden until toggled and only works when wired via
\code{\link[=ptr_ui_toggle_code]{ptr_ui_toggle_code()}}.}
}
\value{
A \link[shiny:reexports]{shiny::tag}.
}
\description{
The generated-code output on its own: a \code{shiny::verbatimTextOutput()}
bound to the \code{ptr_code} id the server writes to (see \code{\link[=ptr_server]{ptr_server()}}).
One of the single-piece UI builders for the L3 "own every UI piece"
workflow.
}
\examples{
ptr_ui_code("myplot")
ptr_ui_code("myplot", style = "window")
}
\seealso{
\code{\link[=ptr_ui_toggle_code]{ptr_ui_toggle_code()}}, \code{\link[=ptr_ui_plot]{ptr_ui_plot()}}, \code{\link[=ptr_server]{ptr_server()}}
}
