feat: resolve #7 theme_civilytics(): default to a transparent background, opt-in for Civilytics cream

This commit is contained in:
2026-06-21 03:13:56 +00:00
parent 41162597cf
commit e256b73053
3 changed files with 45 additions and 17 deletions
+6 -1
View File
@@ -133,8 +133,13 @@ test_that("theme_civilytics uses brand ink color for text", {
expect_equal(th$text$colour, unname(civilytics_colors["ink"]))
})
test_that("theme_civilytics uses brand paper color for plot background", {
test_that("theme_civilytics defaults to transparent plot background", {
th <- theme_civilytics()
expect_true(is.na(th$plot.background$fill))
})
test_that("theme_civilytics paper_bg=TRUE opt-in gives cream background", {
th <- theme_civilytics(paper_bg = TRUE)
expect_equal(th$plot.background$fill, unname(civilytics_colors["paper"]))
})