diff --git a/NAMESPACE b/NAMESPACE index 28081ee..6490181 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -61,7 +61,6 @@ export(v_specs_player) export(v_specs_tooltip) export(v_sunburst) export(v_theme) -export(v_theme_builtin) export(v_treemap) export(v_venn) export(v_waterfall) diff --git a/R/theme.R b/R/theme.R index d82bf23..a2884bc 100644 --- a/R/theme.R +++ b/R/theme.R @@ -124,7 +124,7 @@ v_theme <- function(vc, #' @param name Name of the theme to use, see [available themes online](https://www.visactor.io/vchart/guide/tutorial_docs/Theme/Theme_Extension). #' #' @return A [vchart()] `htmlwidget` object. -#' @export +#' @noRd #' #' @example examples/theme_builtin.R v_theme_builtin <- function(vc, name) { diff --git a/examples/vmap.R b/examples/vmap.R index 2de84b4..fa8cae5 100644 --- a/examples/vmap.R +++ b/examples/vmap.R @@ -24,7 +24,9 @@ if (rlang::is_installed(c("sf", "geojsonio"))) { ) ) %>% v_specs_legend( - orient = "bottom" + orient = "bottom", + type = "color", + field = "fill" ) # Map discrete data diff --git a/man/v_theme_builtin.Rd b/man/v_theme_builtin.Rd deleted file mode 100644 index e5b1eb4..0000000 --- a/man/v_theme_builtin.Rd +++ /dev/null @@ -1,40 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/theme.R -\name{v_theme_builtin} -\alias{v_theme_builtin} -\title{Builtin themes for Charts} -\usage{ -v_theme_builtin(vc, name) -} -\arguments{ -\item{vc}{An htmlwidget created with \code{\link[=vchart]{vchart()}}.} - -\item{name}{Name of the theme to use, see \href{https://www.visactor.io/vchart/guide/tutorial_docs/Theme/Theme_Extension}{available themes online}.} -} -\value{ -A \code{\link[=vchart]{vchart()}} \code{htmlwidget} object. -} -\description{ -Builtin themes for Charts -} -\examples{ - -library(vchartr) - -vchart(top_generation) \%>\% - v_bar(aes(country, electricity_generation)) \%>\% - v_theme_builtin("dark") - -vchart(top_generation) \%>\% - v_bar(aes(country, electricity_generation)) \%>\% - v_theme_builtin("vScreenVolcanoBlue") - -vchart(top_generation) \%>\% - v_bar(aes(country, electricity_generation)) \%>\% - v_theme_builtin("vScreenClean") - -vchart(top_generation) \%>\% - v_bar(aes(country, electricity_generation)) \%>\% - v_theme_builtin("chartHubLight") - -} diff --git a/man/vmap.Rd b/man/vmap.Rd index e6d9a87..76e0a5d 100644 --- a/man/vmap.Rd +++ b/man/vmap.Rd @@ -70,7 +70,9 @@ if (rlang::is_installed(c("sf", "geojsonio"))) { ) ) \%>\% v_specs_legend( - orient = "bottom" + orient = "bottom", + type = "color", + field = "fill" ) # Map discrete data