% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/module_picks.R
\name{.resolve}
\alias{.resolve}
\title{Resolve downstream after selected changes}
\usage{
.resolve(selected, slot_name, picks_resolved, old_picks, data)
}
\arguments{
\item{selected}{(\code{vector}) rather \code{character}, or \code{factor}. \code{numeric(2)} for \code{values()} based on numeric column.}

\item{slot_name}{(\code{character(1)}) one of \code{c("datasets", "variables", "values")}}

\item{picks_resolved}{(\code{reactiveVal})}

\item{old_picks}{(\code{picks})}

\item{data}{(\code{any} asserted further in \code{resolver})}
}
\value{
The result of changing the \code{picks_resolved} \code{reactiveVal} given as argument.
It returns \code{NULL} if it does nothing.
}
\description{
@description
When select input at position \code{i} changes:
\itemize{
\item All slots after position i in \code{picks_resolved} are reset to their unresolved (delayed) state,
because later slots depend on earlier ones. Slots before and at position i are kept as-is.
For example, changing variables (i=2) resets everything after it but keeps dataset (i=1) intact.
\item The new selection replaces the old value at slot i.
\item Resolve is called, which evaluates only the slots that are still in an unresolved state.
\item The updated picks replace the current \code{reactiveValue}.
Thanks to this design reactive values are triggered only once
}
}
\keyword{internal}
