Skip to content

Commit

Permalink
update unicef theme
Browse files Browse the repository at this point in the history
  • Loading branch information
ernestguevarra committed Mar 11, 2024
1 parent 907a57e commit 67cafd3
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 13 deletions.
14 changes: 7 additions & 7 deletions R/theme_unicef.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#'
#'
#' UNICEF colours
#'
#' @examples
Expand Down Expand Up @@ -214,13 +214,13 @@ set_unicef_font <- function(alt = paleta_fonts$paleta_noto) {
#'
theme_unicef <- function(base_family = set_unicef_font(),
plot_title_family = base_family,
plot_title_colour = unicef_blue,
plot_title_colour = unicef_black,
subtitle_family = base_family,
subtitle_colour = unicef_dark_blue,
caption_colour = unicef_dark_blue,
axis_title_colour = unicef_dark_blue,
legend_title_colour = unicef_dark_blue,
legend_text_colour = unicef_dark_blue,
subtitle_colour = unicef_cool_grey,
caption_colour = unicef_cool_grey,
axis_title_colour = unicef_cool_grey,
legend_title_colour = unicef_cool_grey,
legend_text_colour = unicef_cool_grey,
grid_col = unicef_warm_grey,
grid = TRUE,
axis_col = unicef_warm_grey,
Expand Down
3 changes: 0 additions & 3 deletions pkgdown/_pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,6 @@ navbar:
linkedin:
icon: "fab fa-linkedin fa-lg"
href: https://www.linkedin.com/company/katilingban
# github:
# icon: "fab fa-github fa-lg"
# href: https://github.com/katilingban

reference:
- title: Description
Expand Down
6 changes: 3 additions & 3 deletions vignettes/unicef.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Complementing **UNICEF Blue** is a set of 11 secondary colours.
structure(unicef_palettes$unicef_secondary, class = "palette", name = "UNICEF Secondary")
```

The secondary colours can be further subdivided into a set of 7 bright colours and a set of 4 neutral colours.
The secondary colours can be further subdivided into a set of 5 bright colours and a set of 6 neutral colours.

```{r unicef-brights, echo = FALSE, fig.align = "center", fig.height = 1}
structure(unicef_palettes$unicef_brights, class = "palette", name = "UNICEF Brights")
Expand All @@ -60,7 +60,7 @@ ggplot(
geom_bar() +
scale_fill_manual(
name = "Cylinders",
values = unicef_palettes$unicef_brights #|> #tint_colours(p = 0.4) |> unlist()
values = unicef_palettes$unicef_brights
) +
labs(
title = "UNICEF Theme",
Expand All @@ -80,7 +80,7 @@ ggplot(data = mtcars, mapping = aes(x = mpg, y = disp, colour = factor(cyl))) +
) +
labs(
title = "UNICEF Theme",
subtitle = "UNICEF bright palette",
subtitle = "UNICEF brights palette",
) +
theme_unicef()
```
Expand Down

0 comments on commit 67cafd3

Please sign in to comment.