Files
civilyticsR/man/make_logo_grob.Rd
T
jared c93c469267
R-CMD-check / R CMD check (push) Failing after 1m39s
feat: add brand color system, showtext fonts, and dark theme
- R/colors.R: civilytics_colors named vector (from --cv-* CSS vars on
  civilytics.com), three palettes (main/sequential/diverging),
  scale_color_civilytics() and scale_fill_civilytics() for ggplot2
- R/fonts.R: auto-loads Inter + Libre Franklin from Google Fonts via
  showtext in .onLoad(); exports civilytics_load_fonts() for manual retry
- R/theme.R: wires ggplot2 4.0 ink/paper/accent params into theme_grey()
  base, adds title_family + strip_color params; new theme_civilytics_dark()
  using navy_dark background and warm off-white text
- R/logo.R: make_logo_grob(variant) accepts "light"/"dark" to select the
  white logo for dark-background compositions
- DESCRIPTION: adds showtext, sysfonts; pins ggplot2 >= 4.0.0
- tests/testthat/test_theme.R: full test suite for colors, palettes,
  scales, both theme variants, and logo grob variants
2026-05-17 10:36:59 -06:00

26 lines
821 B
R

% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/logo.R
\name{make_logo_grob}
\alias{make_logo_grob}
\title{Get a Civilytics Logo grob}
\usage{
make_logo_grob(variant = c("light", "dark"))
}
\arguments{
\item{variant}{Character. `"light"` (default) uses the standard dark logo
suitable for light backgrounds. `"dark"` uses the white logo suitable for
dark backgrounds (pairs with [theme_civilytics_dark()]).}
}
\value{
A ggplot object (class `"gg"`) containing the logo grob.
}
\description{
Returns a ggplot object containing the Civilytics logo as a rasterGrob,
ready to compose with plots via [add_logo()] or [add_logo_ga()].
}
\examples{
logo <- make_logo_grob() # light background
logo_dark <- make_logo_grob("dark") # dark background
class(logo) # "gg" "ggplot"
}