Просмотр исходного кода

Add base_font_size and convert font sizes to rem

Now, font size is inherited from `base_font_size` which should be in absolute units.
tags/v0.3.0
Garrick Aden-Buie 6 лет назад
Родитель
Сommit
85f512caa9
26 измененных файлов: 519 добавлений и 416 удалений
  1. +2
    -1
      DESCRIPTION
  2. +17
    -3
      R/ggplot2.R
  3. +22
    -20
      R/style_duo.R
  4. +22
    -20
      R/style_duo_accent.R
  5. +22
    -20
      R/style_duo_accent_inverse.R
  6. +22
    -20
      R/style_mono_accent.R
  7. +22
    -20
      R/style_mono_accent_inverse.R
  8. +22
    -20
      R/style_mono_dark.R
  9. +22
    -20
      R/style_mono_light.R
  10. +22
    -20
      R/style_solarized_dark.R
  11. +22
    -20
      R/style_solarized_light.R
  12. +36
    -20
      R/style_xaringan.R
  13. +11
    -10
      R/theme_settings.R
  14. +3
    -2
      inst/resources/template.css
  15. +14
    -0
      inst/scripts/style_xaringan_body.R
  16. +23
    -20
      man/style_duo.Rd
  17. +23
    -20
      man/style_duo_accent.Rd
  18. +23
    -20
      man/style_duo_accent_inverse.Rd
  19. +23
    -20
      man/style_mono_accent.Rd
  20. +23
    -20
      man/style_mono_accent_inverse.Rd
  21. +23
    -20
      man/style_mono_dark.Rd
  22. +23
    -20
      man/style_mono_light.Rd
  23. +23
    -20
      man/style_solarized_dark.Rd
  24. +23
    -20
      man/style_solarized_light.Rd
  25. +23
    -20
      man/style_xaringan.Rd
  26. +8
    -0
      tests/testthat/test-style_xaringan.R

+ 2
- 1
DESCRIPTION Просмотреть файл

@@ -32,7 +32,8 @@ Suggests:
showtext,
sysfonts,
testthat (>= 2.1.0),
xaringan
xaringan,
vdiffr
VignetteBuilder:
knitr
Encoding: UTF-8

+ 17
- 3
R/ggplot2.R Просмотреть файл

@@ -816,19 +816,33 @@ theme_xaringan_get_value <- function(setting, css_file = NULL) {
}
}

web_to_point <- function(x, px_per_em = 16, scale = 1) {
web_to_point <- function(x, px_per_em = NULL, scale = 1) {
if (is.null(x)) {
return(NULL)
}
px_per_em <- px_per_em %||% get_base_font_size()
if (grepl("pt$", x)) {
return(as.numeric(sub("pt$", "", x)))
} else if (grepl("px$", x)) {
x <- as.numeric(sub("px$", "", x))
return(x * 0.75)
} else if (grepl("em$", x)) {
x <- as.numeric(sub("em$", "", x))
} else if (grepl("r?em$", x)) {
x <- as.numeric(sub("r?em$", "", x))
return(x * px_per_em * 0.75)
} else {
return()
}
}

get_base_font_size <- function() {
base_size <- xaringanthemer_env[["base_font_size"]]
if (is.null(base_size)) {
base_size <- xaringanthemer_env[["text_font_size"]]
}
if (!grepl("px", base_size)) {
# assume 16px base font size
16
} else {
as.numeric(sub("px", "", base_size))
}
}

+ 22
- 20
R/style_duo.R Просмотреть файл

@@ -6,14 +6,14 @@
#' @param link_color Link Color. Defaults to `secondary_color`. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `secondary_color`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `text_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to `secondary_color`. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to `secondary_color`. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to `primary_color`. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -24,25 +24,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to `apply_alpha(secondary_color, 0.6)`. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to `secondary_color`. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to `apply_alpha(secondary_color, 0.5)`. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to `lighten_color(primary_color, 0.3)`. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -55,7 +56,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -79,14 +80,14 @@ style_duo <- function(
link_color = secondary_color,
text_bold_color = secondary_color,
text_slide_number_color = text_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = secondary_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = secondary_color,
inverse_text_color = primary_color,
inverse_text_shadow = FALSE,
@@ -97,25 +98,26 @@ style_duo <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(secondary_color, 0.6),
left_column_selected_color = secondary_color,
blockquote_left_border_color = apply_alpha(secondary_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(primary_color, 0.3),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -128,7 +130,7 @@ style_duo <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_duo_accent.R Просмотреть файл

@@ -8,14 +8,14 @@
#' @param link_color Link Color. Defaults to `choose_dark_or_light(secondary_color, primary_color, secondary_color)`. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `choose_dark_or_light(secondary_color, primary_color, secondary_color)`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `primary_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to `choose_dark_or_light(secondary_color, primary_color, secondary_color)`. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to `secondary_color`. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to `choose_dark_or_light(secondary_color, black_color, white_color)`. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -26,25 +26,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to `apply_alpha(primary_color, 0.6)`. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to `primary_color`. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to `apply_alpha(secondary_color, 0.5)`. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to `lighten_color(secondary_color, 0.3)`. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -57,7 +58,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -83,14 +84,14 @@ style_duo_accent <- function(
link_color = choose_dark_or_light(secondary_color, primary_color, secondary_color),
text_bold_color = choose_dark_or_light(secondary_color, primary_color, secondary_color),
text_slide_number_color = primary_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = choose_dark_or_light(secondary_color, primary_color, secondary_color),
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = secondary_color,
inverse_text_color = choose_dark_or_light(secondary_color, black_color, white_color),
inverse_text_shadow = FALSE,
@@ -101,25 +102,26 @@ style_duo_accent <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(primary_color, 0.6),
left_column_selected_color = primary_color,
blockquote_left_border_color = apply_alpha(secondary_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(secondary_color, 0.3),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -132,7 +134,7 @@ style_duo_accent <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_duo_accent_inverse.R Просмотреть файл

@@ -8,14 +8,14 @@
#' @param link_color Link Color. Defaults to `choose_dark_or_light(secondary_color, secondary_color, primary_color)`. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `choose_dark_or_light(secondary_color, secondary_color, primary_color)`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `primary_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to `choose_dark_or_light(secondary_color, secondary_color, primary_color)`. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to `secondary_color`. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to `choose_dark_or_light(secondary_color, black_color, white_color)`. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -26,25 +26,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to `apply_alpha(primary_color, 0.6)`. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to `primary_color`. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to `apply_alpha(secondary_color, 0.5)`. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to `darken_color(choose_dark_or_light(primary_color, secondary_color, primary_color), 0.3)`. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -57,7 +58,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -83,14 +84,14 @@ style_duo_accent_inverse <- function(
link_color = choose_dark_or_light(secondary_color, secondary_color, primary_color),
text_bold_color = choose_dark_or_light(secondary_color, secondary_color, primary_color),
text_slide_number_color = primary_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = choose_dark_or_light(secondary_color, secondary_color, primary_color),
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = secondary_color,
inverse_text_color = choose_dark_or_light(secondary_color, black_color, white_color),
inverse_text_shadow = FALSE,
@@ -101,25 +102,26 @@ style_duo_accent_inverse <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(primary_color, 0.6),
left_column_selected_color = primary_color,
blockquote_left_border_color = apply_alpha(secondary_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = darken_color(choose_dark_or_light(primary_color, secondary_color, primary_color), 0.3),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -132,7 +134,7 @@ style_duo_accent_inverse <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_mono_accent.R Просмотреть файл

@@ -7,14 +7,14 @@
#' @param link_color Link Color. Defaults to `base_color`. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `base_color`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `base_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to `base_color`. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to `base_color`. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to `white_color`. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -25,25 +25,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to `apply_alpha(base_color, 0.6)`. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to `base_color`. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to `apply_alpha(base_color, 0.5)`. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to `lighten_color(base_color, 0.7)`. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -56,7 +57,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -81,14 +82,14 @@ style_mono_accent <- function(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = white_color,
inverse_text_shadow = FALSE,
@@ -99,25 +100,26 @@ style_mono_accent <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(base_color, 0.7),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -130,7 +132,7 @@ style_mono_accent <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_mono_accent_inverse.R Просмотреть файл

@@ -7,14 +7,14 @@
#' @param link_color Link Color. Defaults to `base_color`. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `base_color`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `base_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to `base_color`. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to `base_color`. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to `black_color`. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -25,25 +25,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to `apply_alpha(base_color, 0.6)`. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to `base_color`. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to `apply_alpha(base_color, 0.5)`. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to `darken_color(base_color, 0.7)`. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -56,7 +57,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -81,14 +82,14 @@ style_mono_accent_inverse <- function(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = black_color,
inverse_text_shadow = FALSE,
@@ -99,25 +100,26 @@ style_mono_accent_inverse <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = darken_color(base_color, 0.7),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -130,7 +132,7 @@ style_mono_accent_inverse <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_mono_dark.R Просмотреть файл

@@ -7,14 +7,14 @@
#' @param link_color Link Color. Defaults to `base_color`. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `base_color`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `base_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to `base_color`. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to `base_color`. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to `black_color`. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -25,25 +25,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to `apply_alpha(base_color, 0.6)`. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to `base_color`. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to `apply_alpha(base_color, 0.5)`. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to `darken_color(base_color, 0.7)`. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -56,7 +57,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -81,14 +82,14 @@ style_mono_dark <- function(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = black_color,
inverse_text_shadow = FALSE,
@@ -99,25 +100,26 @@ style_mono_dark <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = darken_color(base_color, 0.7),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -130,7 +132,7 @@ style_mono_dark <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_mono_light.R Просмотреть файл

@@ -7,14 +7,14 @@
#' @param link_color Link Color. Defaults to `base_color`. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `base_color`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `base_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to `base_color`. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to `base_color`. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to `white_color`. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -25,25 +25,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to `apply_alpha(base_color, 0.6)`. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to `base_color`. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to `apply_alpha(base_color, 0.5)`. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to `lighten_color(base_color, 0.8)`. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -56,7 +57,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -81,14 +82,14 @@ style_mono_light <- function(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = white_color,
inverse_text_shadow = FALSE,
@@ -99,25 +100,26 @@ style_mono_light <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(base_color, 0.8),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -130,7 +132,7 @@ style_mono_light <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_solarized_dark.R Просмотреть файл

@@ -4,14 +4,14 @@
#' @param link_color Link Color. Defaults to #b58900. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to #d33682. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to #586e75. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to #268bd240. Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to #6c71c4. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to #fdf6e3. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to #002b36. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -22,25 +22,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to #586e75. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to #93a1a1. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to #cb4b16. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #657b83. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #657b83. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to #073642. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -53,7 +54,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -75,14 +76,14 @@ style_solarized_dark <- function(
link_color = "#b58900",
text_bold_color = "#d33682",
text_slide_number_color = "#586e75",
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "#268bd240",
code_inline_color = "#6c71c4",
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = "#fdf6e3",
inverse_text_color = "#002b36",
inverse_text_shadow = FALSE,
@@ -93,25 +94,26 @@ style_solarized_dark <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = "#586e75",
left_column_selected_color = "#93a1a1",
blockquote_left_border_color = "#cb4b16",
table_border_color = "#657b83",
table_row_border_color = "#657b83",
table_row_even_background_color = "#073642",
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -124,7 +126,7 @@ style_solarized_dark <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 22
- 20
R/style_solarized_light.R Просмотреть файл

@@ -4,14 +4,14 @@
#' @param link_color Link Color. Defaults to #b58900. Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to #d33682. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to #93a1a1. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to #268bd240. Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to #6c71c4. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to #002b36. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to #fdf6e3. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -22,25 +22,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to #93a1a1. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to #586e75. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to #cb4b16. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #839496. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #839496. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to #eee8d5. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -53,7 +54,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -75,14 +76,14 @@ style_solarized_light <- function(
link_color = "#b58900",
text_bold_color = "#d33682",
text_slide_number_color = "#93a1a1",
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "#268bd240",
code_inline_color = "#6c71c4",
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = "#002b36",
inverse_text_color = "#fdf6e3",
inverse_text_shadow = FALSE,
@@ -93,25 +94,26 @@ style_solarized_light <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = "#93a1a1",
left_column_selected_color = "#586e75",
blockquote_left_border_color = "#cb4b16",
table_border_color = "#839496",
table_row_border_color = "#839496",
table_row_even_background_color = "#eee8d5",
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -124,7 +126,7 @@ style_solarized_light <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,

+ 36
- 20
R/style_xaringan.R Просмотреть файл

@@ -4,14 +4,14 @@
#' @param link_color Link Color. Defaults to rgb(249, 38, 114). Modifies the `a, a > code` elements.
#' @param text_bold_color Bold Text Color. Defaults to `NULL`. Modifies the `strong` element.
#' @param text_slide_number_color Slide Number Color. Defaults to `inverse_background_color`. Modifies the `.remark-slide-number` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 1rem 4rem 1rem 4rem. Modifies the `.remark-slide-content` class.
#' @param padding Slide Padding in `top right [bottom left]` format. Defaults to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
#' @param background_image Background image applied to each *and every* slide. Set `title_slide_background_image = "none"` to remove the background image from the title slide. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_size Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param background_position Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`. Defaults to `NULL`. Modifies the `.remark-slide-content` class.
#' @param code_highlight_color Code Line Highlight. Defaults to rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
#' @param code_inline_color Inline Code Color. Defaults to #000. Modifies the `.remark-inline-code` class.
#' @param code_inline_background_color Inline Code Background Color. Defaults to `NULL`. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em. Modifies the `.remark-inline-code` class.
#' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1rem. Modifies the `.remark-inline-code` class.
#' @param inverse_background_color Inverse Background Color. Defaults to #272822. Modifies the `.inverse` class.
#' @param inverse_text_color Inverse Text Color. Defaults to #d6d6d6. Modifies the `.inverse` class.
#' @param inverse_text_shadow Enables Shadow on text of inverse slides. Defaults to `FALSE`. Modifies the `.inverse` class.
@@ -22,25 +22,26 @@
#' @param title_slide_background_size Title Slide Background Image Size, defaults to "cover" if background image is set. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param title_slide_background_position Title Slide Background Image Position. Defaults to `NULL`. Modifies the `.title-slide` class.
#' @param footnote_color Footnote text color (if `NA`, then it will be the same color as `text_color`). Defaults to `NULL`. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 3em. Modifies the `.footnote` class.
#' @param footnote_font_size Footnote font size. Defaults to 0.9rem. Modifies the `.footnote` class.
#' @param footnote_position_bottom Footnote location from bottom of screen. Defaults to 60px. Modifies the `.footnote` class.
#' @param left_column_subtle_color Left Column Text (not last). Defaults to #777. Modifies the `.left-column h2, .left-column h3` classes.
#' @param left_column_selected_color Left Column Current Selection. Defaults to #000. Modifies the `.left-column h2:last-of-type, .left-column h3:last-child` classes.
#' @param blockquote_left_border_color Blockquote Left Border Color. Defaults to lightgray. Modifies the `blockquote` element.
#' @param table_border_color Table top/bottom border. Defaults to #666. Modifies the `table: border-top, border-bottom` elements.
#' @param table_row_border_color Table row inner bottom border. Defaults to #ddd. Modifies the `table thead th: border-bottom` elements.
#' @param table_row_even_background_color Table Even Row Background Color. Defaults to #eee. Modifies the `thead, tfoot, tr:nth-child(even)` elements.
#' @param text_font_size Slide Body Text Font Size. Defaults to 20px. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 55px. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 45px. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 35px. Modifies the `.remark-slide-content h3` class.
#' @param base_font_size Base Font Size for All Slide Elements (must be `px`). Defaults to 20px. Modifies the `html` element.
#' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies the `.remark-slide-content` class.
#' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem. Modifies the `.remark-slide-content h1` class.
#' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem. Modifies the `.remark-slide-content h2` class.
#' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem. Modifies the `.remark-slide-content h3` class.
#' @param header_background_auto Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable. Defaults to `FALSE`.
#' @param header_background_color Background Color for h1 Header with Background. Defaults to `header_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_text_color Text Color for h1 Header with Background. Defaults to `background_color`. Modifies the `.remark-slide-content h1` class.
#' @param header_background_padding Padding for h1 Header with Background. Defaults to 2rem 4rem 1.5rem 4rem. Modifies the `.remark-slide-content h1` class.
#' @param header_background_content_padding_top Top Padding for Content in Slide with Header with Background. Defaults to 7rem. Modifies the `.remark-slide-content` class.
#' @param header_background_ignore_classes Slide Classes Where Header with Background will not be Applied. Defaults to `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the `.remark-slide-content` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9em. Modifies the `.remark-slide-number` class.
#' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to 0.9rem. Modifies the `.remark-slide-number` class.
#' @param text_font_google Use `google_font()` to specify body font. Defaults to `NULL`. Modifies the `body` element.
#' @param text_font_family Body Text Font Family. Defaults to 'Droid Serif'. Modifies the `body` element.
#' @param text_font_weight Body Text Font Weight. Defaults to normal. Modifies the `body` element.
@@ -53,7 +54,7 @@
#' @param header_font_url Header Font URL. Defaults to https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz. Modifies the `@import url` elements.
#' @param code_font_google Use `google_font()` to specify code font. Defaults to `NULL`. Modifies the `body` element.
#' @param code_font_family Code Font Family. Defaults to 'Source Code Pro'. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param code_font_size Code Text Font Size. Defaults to 0.9em. Modifies the `.remark-inline` class.
#' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the `.remark-inline` class.
#' @param code_font_url Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the `@import url` elements.
#' @param code_font_family_fallback Code Font Fallback. Defaults to 'Lucida Console', Monaco. Modifies the `.remark-code, .remark-inline-code` classes.
#' @param colors A named vector of custom colors. The names of the colors
@@ -74,14 +75,14 @@ style_xaringan <- function(
link_color = "rgb(249, 38, 114)",
text_bold_color = NULL,
text_slide_number_color = inverse_background_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = "#000",
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = "#272822",
inverse_text_color = "#d6d6d6",
inverse_text_shadow = FALSE,
@@ -92,25 +93,26 @@ style_xaringan <- function(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = "#777",
left_column_selected_color = "#000",
blockquote_left_border_color = "lightgray",
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = "#eee",
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -123,7 +125,7 @@ style_xaringan <- function(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -140,6 +142,20 @@ style_xaringan <- function(
eval(parse(text = paste0(sub("font_family$", "font_is_google", var), "<-0")))
}
# Warn if base_font_size isn't absolute
css_abs_units <- c("cm", "mm", "Q", "in", "pc", "pt", "px")
if (!grepl(paste(tolower(css_abs_units), collapse = "|"), tolower(base_font_size))) {
warning(
glue::glue(
"Base font size '{base_font_size}' is not in absolute units. ",
"For best results, specify the `base_font_size` using absolute CSS units: ",
"{paste(css_abs_units, collapse = ', ')}"
),
call. = FALSE,
immediate. = TRUE
)
}
# Use font_..._google args to overwrite font args
for (var in f_args[grepl("font_google$", f_args)]) {
gf <- eval(parse(text = var))

+ 11
- 10
R/theme_settings.R Просмотреть файл

@@ -7,14 +7,14 @@ template_variables <- tibble::tribble(
, "link_color", "rgb(249, 38, 114)", "a, a > code", "Link Color"
, "text_bold_color", NULL, "strong", "Bold Text Color"
, "text_slide_number_color", "{inverse_background_color}", ".remark-slide-number", "Slide Number Color"
, "padding", "1rem 4rem 1rem 4rem", ".remark-slide-content", "Slide Padding in `top right [bottom left]` format"
, "padding", "16px 64px 16px 64px", ".remark-slide-content", "Slide Padding in `top right [bottom left]` format"
, "background_image", NULL, ".remark-slide-content", "Background image applied to each *and every* slide. Set `title_slide_background_image = \"none\"` to remove the background image from the title slide"
, "background_size", NULL, ".remark-slide-content", "Background image size, requires `background_image` to be set. If `background_image` is set, `background_size` will default to `cover` so the backround fills the screen. If both `background_image` and `background_position` are set, will default to 100 percent"
, "background_position", NULL, ".remark-slide-content", "Background image position, requires `background_image` to be set, and it is recommended to adjust `background_size`"
, "code_highlight_color", "rgba(255,255,0,0.5)", ".remark-code-line-highlighted", "Code Line Highlight"
, "code_inline_color", "#000", ".remark-inline-code", "Inline Code Color"
, "code_inline_background_color", NULL, ".remark-inline-code", "Inline Code Background Color"
, "code_inline_font_size", "1em", ".remark-inline-code", "Inline Code Text Font Size"
, "code_inline_font_size", "1rem", ".remark-inline-code", "Inline Code Text Font Size"
, "inverse_background_color", "#272822", ".inverse", "Inverse Background Color"
, "inverse_text_color", "#d6d6d6", ".inverse", "Inverse Text Color"
, "inverse_text_shadow", "{FALSE}", ".inverse", "Enables Shadow on text of inverse slides"
@@ -25,25 +25,26 @@ template_variables <- tibble::tribble(
, "title_slide_background_size", NULL, ".title-slide", "Title Slide Background Image Size, defaults to \"cover\" if background image is set"
, "title_slide_background_position", NULL, ".title-slide", "Title Slide Background Image Position"
, "footnote_color", NULL, ".footnote", "Footnote text color (if `NA`, then it will be the same color as `text_color`)"
, "footnote_font_size", "0.9em", ".footnote", "Footnote font size"
, "footnote_position_bottom", "3em", ".footnote", "Footnote location from bottom of screen"
, "footnote_font_size", "0.9rem", ".footnote", "Footnote font size"
, "footnote_position_bottom", "60px", ".footnote", "Footnote location from bottom of screen"
, "left_column_subtle_color", "#777", ".left-column h2, .left-column h3", "Left Column Text (not last)"
, "left_column_selected_color", "#000", ".left-column h2:last-of-type, .left-column h3:last-child", "Left Column Current Selection"
, "blockquote_left_border_color", "lightgray", "blockquote", "Blockquote Left Border Color"
, "table_border_color", "#666", "table: border-top, border-bottom", "Table top/bottom border"
, "table_row_border_color", "#ddd", "table thead th: border-bottom", "Table row inner bottom border"
, "table_row_even_background_color", "#eee", "thead, tfoot, tr:nth-child(even)", "Table Even Row Background Color"
, "text_font_size", "20px", ".remark-slide-content", "Slide Body Text Font Size"
, "header_h1_font_size", "55px", ".remark-slide-content h1", "h1 Header Text Font Size"
, "header_h2_font_size", "45px", ".remark-slide-content h2", "h2 Header Text Font Size"
, "header_h3_font_size", "35px", ".remark-slide-content h3", "h3 Header Text Font Size"
, "base_font_size", "20px", "html", "Base Font Size for All Slide Elements (must be `px`)"
, "text_font_size", "1rem", ".remark-slide-content", "Slide Body Text Font Size"
, "header_h1_font_size", "2.75rem", ".remark-slide-content h1", "h1 Header Text Font Size"
, "header_h2_font_size", "2.25rem", ".remark-slide-content h2", "h2 Header Text Font Size"
, "header_h3_font_size", "1.75rem", ".remark-slide-content h3", "h3 Header Text Font Size"
, "header_background_auto", "{FALSE}", "", "Add background under slide title automatically for h1 header elements. If not enabled, use `class: header_background` to enable"
, "header_background_color", "{header_color}", ".remark-slide-content h1", "Background Color for h1 Header with Background"
, "header_background_text_color", "{background_color}", ".remark-slide-content h1", "Text Color for h1 Header with Background"
, "header_background_padding", "2rem 4rem 1.5rem 4rem", ".remark-slide-content h1", "Padding for h1 Header with Background"
, "header_background_content_padding_top", "7rem", ".remark-slide-content", "Top Padding for Content in Slide with Header with Background"
, "header_background_ignore_classes", "{c('normal', 'inverse', 'title', 'middle', 'bottom')}", ".remark-slide-content", "Slide Classes Where Header with Background will not be Applied"
, "text_slide_number_font_size", "0.9em", ".remark-slide-number", "Slide Number Text Font Size"
, "text_slide_number_font_size", "0.9rem", ".remark-slide-number", "Slide Number Text Font Size"
, "text_font_google", NULL, "body", "Use `google_font()` to specify body font"
, "text_font_family", "'Droid Serif'", "body", "Body Text Font Family"
, "text_font_weight", "normal", "body", "Body Text Font Weight"
@@ -56,7 +57,7 @@ template_variables <- tibble::tribble(
, "header_font_url", "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz", "@import url", "Header Font URL"
, "code_font_google", NULL, "body", "Use `google_font()` to specify code font"
, "code_font_family", "'Source Code Pro'", ".remark-code, .remark-inline-code", "Code Font Family"
, "code_font_size", "0.9em", ".remark-inline", "Code Text Font Size"
, "code_font_size", "0.9rem", ".remark-inline", "Code Text Font Size"
, "code_font_url", "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700", "@import url", "Code Font URL"
, "code_font_family_fallback", "'Lucida Console', Monaco", ".remark-code, .remark-inline-code", "Code Font Fallback"
)

+ 3
- 2
inst/resources/template.css Просмотреть файл

@@ -33,6 +33,7 @@
--header-font-is-google: {{header_font_is_google}};
--code-font-family: {{code_font_family}};
--code-font-is-google: {{code_font_is_google}};
--base-font-size: {{base_font_size}};
--text-font-size: {{text_font_size}};
--code-font-size: {{code_font_size}};
--code-inline-font-size: {{code_inline_font_size}};
@@ -60,7 +61,7 @@
}

html {
font-size: var(--text-font-size);
font-size: var(--base-font-size);
}

body {
@@ -75,7 +76,7 @@ h1, h2, h3 {
}
.remark-slide-content {
background-color: var(--background-color);
font-size: var(--text-font-size);{{#background_image}}
font-size: {{text_font_size}};{{#background_image}}
background-image: url({{background_image}});{{#background_size}}
background-size: {{background_size}};{{/background_size}}{{#background_position}}
background-position: {{background_position}};{{/background_position}}{{/background_image}}

+ 14
- 0
inst/scripts/style_xaringan_body.R Просмотреть файл

@@ -6,6 +6,20 @@ for (var in f_args[grepl("font_family$", f_args)]) {
eval(parse(text = paste0(sub("font_family$", "font_is_google", var), "<-0")))
}

# Warn if base_font_size isn't absolute
css_abs_units <- c("cm", "mm", "Q", "in", "pc", "pt", "px")
if (!grepl(paste(tolower(css_abs_units), collapse = "|"), tolower(base_font_size))) {
warning(
glue::glue(
"Base font size '{base_font_size}' is not in absolute units. ",
"For best results, specify the `base_font_size` using absolute CSS units: ",
"{paste(css_abs_units, collapse = ', ')}"
),
call. = FALSE,
immediate. = TRUE
)
}

# Use font_..._google args to overwrite font args
for (var in f_args[grepl("font_google$", f_args)]) {
gf <- eval(parse(text = var))

+ 23
- 20
man/style_duo.Rd Просмотреть файл

@@ -14,14 +14,14 @@ style_duo(
link_color = secondary_color,
text_bold_color = secondary_color,
text_slide_number_color = text_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = secondary_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = secondary_color,
inverse_text_color = primary_color,
inverse_text_shadow = FALSE,
@@ -32,25 +32,26 @@ style_duo(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(secondary_color, 0.6),
left_column_selected_color = secondary_color,
blockquote_left_border_color = apply_alpha(secondary_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(primary_color, 0.3),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -65,7 +66,7 @@ style_duo(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -91,7 +92,7 @@ style_duo(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{text_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -105,7 +106,7 @@ style_duo(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to \code{secondary_color}. Modifies the \code{.inverse} class.}

@@ -127,9 +128,9 @@ style_duo(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to \code{apply_alpha(secondary_color, 0.6)}. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -143,13 +144,15 @@ style_duo(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to \code{lighten_color(primary_color, 0.3)}. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -163,7 +166,7 @@ style_duo(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -189,7 +192,7 @@ style_duo(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_duo_accent.Rd Просмотреть файл

@@ -16,7 +16,7 @@ style_duo_accent(
text_bold_color = choose_dark_or_light(secondary_color, primary_color,
secondary_color),
text_slide_number_color = primary_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
@@ -24,7 +24,7 @@ style_duo_accent(
code_inline_color = choose_dark_or_light(secondary_color, primary_color,
secondary_color),
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = secondary_color,
inverse_text_color = choose_dark_or_light(secondary_color, black_color, white_color),
inverse_text_shadow = FALSE,
@@ -35,25 +35,26 @@ style_duo_accent(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(primary_color, 0.6),
left_column_selected_color = primary_color,
blockquote_left_border_color = apply_alpha(secondary_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(secondary_color, 0.3),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -68,7 +69,7 @@ style_duo_accent(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -98,7 +99,7 @@ style_duo_accent(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{primary_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -112,7 +113,7 @@ style_duo_accent(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to \code{secondary_color}. Modifies the \code{.inverse} class.}

@@ -134,9 +135,9 @@ style_duo_accent(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to \code{apply_alpha(primary_color, 0.6)}. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -150,13 +151,15 @@ style_duo_accent(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to \code{lighten_color(secondary_color, 0.3)}. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -170,7 +173,7 @@ style_duo_accent(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -196,7 +199,7 @@ style_duo_accent(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_duo_accent_inverse.Rd Просмотреть файл

@@ -16,7 +16,7 @@ style_duo_accent_inverse(
text_bold_color = choose_dark_or_light(secondary_color, secondary_color,
primary_color),
text_slide_number_color = primary_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
@@ -24,7 +24,7 @@ style_duo_accent_inverse(
code_inline_color = choose_dark_or_light(secondary_color, secondary_color,
primary_color),
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = secondary_color,
inverse_text_color = choose_dark_or_light(secondary_color, black_color, white_color),
inverse_text_shadow = FALSE,
@@ -35,8 +35,8 @@ style_duo_accent_inverse(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(primary_color, 0.6),
left_column_selected_color = primary_color,
blockquote_left_border_color = apply_alpha(secondary_color, 0.5),
@@ -44,17 +44,18 @@ style_duo_accent_inverse(
table_row_border_color = "#ddd",
table_row_even_background_color = darken_color(choose_dark_or_light(primary_color,
secondary_color, primary_color), 0.3),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -69,7 +70,7 @@ style_duo_accent_inverse(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -99,7 +100,7 @@ style_duo_accent_inverse(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{primary_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -113,7 +114,7 @@ style_duo_accent_inverse(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to \code{secondary_color}. Modifies the \code{.inverse} class.}

@@ -135,9 +136,9 @@ style_duo_accent_inverse(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to \code{apply_alpha(primary_color, 0.6)}. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -151,13 +152,15 @@ style_duo_accent_inverse(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to \code{darken_color(choose_dark_or_light(primary_color, secondary_color, primary_color), 0.3)}. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -171,7 +174,7 @@ style_duo_accent_inverse(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -197,7 +200,7 @@ style_duo_accent_inverse(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_mono_accent.Rd Просмотреть файл

@@ -14,14 +14,14 @@ style_mono_accent(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = white_color,
inverse_text_shadow = FALSE,
@@ -32,25 +32,26 @@ style_mono_accent(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(base_color, 0.7),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -65,7 +66,7 @@ style_mono_accent(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -93,7 +94,7 @@ style_mono_accent(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{base_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -107,7 +108,7 @@ style_mono_accent(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to \code{base_color}. Modifies the \code{.inverse} class.}

@@ -129,9 +130,9 @@ style_mono_accent(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to \code{apply_alpha(base_color, 0.6)}. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -145,13 +146,15 @@ style_mono_accent(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to \code{lighten_color(base_color, 0.7)}. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -165,7 +168,7 @@ style_mono_accent(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -191,7 +194,7 @@ style_mono_accent(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_mono_accent_inverse.Rd Просмотреть файл

@@ -14,14 +14,14 @@ style_mono_accent_inverse(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = black_color,
inverse_text_shadow = FALSE,
@@ -32,25 +32,26 @@ style_mono_accent_inverse(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = darken_color(base_color, 0.7),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -65,7 +66,7 @@ style_mono_accent_inverse(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -93,7 +94,7 @@ style_mono_accent_inverse(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{base_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -107,7 +108,7 @@ style_mono_accent_inverse(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to \code{base_color}. Modifies the \code{.inverse} class.}

@@ -129,9 +130,9 @@ style_mono_accent_inverse(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to \code{apply_alpha(base_color, 0.6)}. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -145,13 +146,15 @@ style_mono_accent_inverse(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to \code{darken_color(base_color, 0.7)}. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -165,7 +168,7 @@ style_mono_accent_inverse(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -191,7 +194,7 @@ style_mono_accent_inverse(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_mono_dark.Rd Просмотреть файл

@@ -14,14 +14,14 @@ style_mono_dark(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = black_color,
inverse_text_shadow = FALSE,
@@ -32,25 +32,26 @@ style_mono_dark(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = darken_color(base_color, 0.7),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -65,7 +66,7 @@ style_mono_dark(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -93,7 +94,7 @@ style_mono_dark(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{base_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -107,7 +108,7 @@ style_mono_dark(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to \code{base_color}. Modifies the \code{.inverse} class.}

@@ -129,9 +130,9 @@ style_mono_dark(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to \code{apply_alpha(base_color, 0.6)}. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -145,13 +146,15 @@ style_mono_dark(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to \code{darken_color(base_color, 0.7)}. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -165,7 +168,7 @@ style_mono_dark(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -191,7 +194,7 @@ style_mono_dark(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_mono_light.Rd Просмотреть файл

@@ -14,14 +14,14 @@ style_mono_light(
link_color = base_color,
text_bold_color = base_color,
text_slide_number_color = base_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = base_color,
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = base_color,
inverse_text_color = white_color,
inverse_text_shadow = FALSE,
@@ -32,25 +32,26 @@ style_mono_light(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = apply_alpha(base_color, 0.6),
left_column_selected_color = base_color,
blockquote_left_border_color = apply_alpha(base_color, 0.5),
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = lighten_color(base_color, 0.8),
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -65,7 +66,7 @@ style_mono_light(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -93,7 +94,7 @@ style_mono_light(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{base_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -107,7 +108,7 @@ style_mono_light(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to \code{base_color}. Modifies the \code{.inverse} class.}

@@ -129,9 +130,9 @@ style_mono_light(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to \code{apply_alpha(base_color, 0.6)}. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -145,13 +146,15 @@ style_mono_light(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to \code{lighten_color(base_color, 0.8)}. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -165,7 +168,7 @@ style_mono_light(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -191,7 +194,7 @@ style_mono_light(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_solarized_dark.Rd Просмотреть файл

@@ -11,14 +11,14 @@ style_solarized_dark(
link_color = "#b58900",
text_bold_color = "#d33682",
text_slide_number_color = "#586e75",
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "#268bd240",
code_inline_color = "#6c71c4",
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = "#fdf6e3",
inverse_text_color = "#002b36",
inverse_text_shadow = FALSE,
@@ -29,25 +29,26 @@ style_solarized_dark(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = "#586e75",
left_column_selected_color = "#93a1a1",
blockquote_left_border_color = "#cb4b16",
table_border_color = "#657b83",
table_row_border_color = "#657b83",
table_row_even_background_color = "#073642",
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -62,7 +63,7 @@ style_solarized_dark(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -84,7 +85,7 @@ style_solarized_dark(

\item{text_slide_number_color}{Slide Number Color. Defaults to #586e75. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -98,7 +99,7 @@ style_solarized_dark(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to #fdf6e3. Modifies the \code{.inverse} class.}

@@ -120,9 +121,9 @@ style_solarized_dark(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to #586e75. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -136,13 +137,15 @@ style_solarized_dark(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to #073642. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -156,7 +159,7 @@ style_solarized_dark(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -182,7 +185,7 @@ style_solarized_dark(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_solarized_light.Rd Просмотреть файл

@@ -11,14 +11,14 @@ style_solarized_light(
link_color = "#b58900",
text_bold_color = "#d33682",
text_slide_number_color = "#93a1a1",
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "#268bd240",
code_inline_color = "#6c71c4",
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = "#002b36",
inverse_text_color = "#fdf6e3",
inverse_text_shadow = FALSE,
@@ -29,25 +29,26 @@ style_solarized_light(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = "#93a1a1",
left_column_selected_color = "#586e75",
blockquote_left_border_color = "#cb4b16",
table_border_color = "#839496",
table_row_border_color = "#839496",
table_row_even_background_color = "#eee8d5",
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -62,7 +63,7 @@ style_solarized_light(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -84,7 +85,7 @@ style_solarized_light(

\item{text_slide_number_color}{Slide Number Color. Defaults to #93a1a1. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -98,7 +99,7 @@ style_solarized_light(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to #002b36. Modifies the \code{.inverse} class.}

@@ -120,9 +121,9 @@ style_solarized_light(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to #93a1a1. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -136,13 +137,15 @@ style_solarized_light(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to #eee8d5. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -156,7 +159,7 @@ style_solarized_light(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -182,7 +185,7 @@ style_solarized_light(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 23
- 20
man/style_xaringan.Rd Просмотреть файл

@@ -11,14 +11,14 @@ style_xaringan(
link_color = "rgb(249, 38, 114)",
text_bold_color = NULL,
text_slide_number_color = inverse_background_color,
padding = "1rem 4rem 1rem 4rem",
padding = "16px 64px 16px 64px",
background_image = NULL,
background_size = NULL,
background_position = NULL,
code_highlight_color = "rgba(255,255,0,0.5)",
code_inline_color = "#000",
code_inline_background_color = NULL,
code_inline_font_size = "1em",
code_inline_font_size = "1rem",
inverse_background_color = "#272822",
inverse_text_color = "#d6d6d6",
inverse_text_shadow = FALSE,
@@ -29,25 +29,26 @@ style_xaringan(
title_slide_background_size = NULL,
title_slide_background_position = NULL,
footnote_color = NULL,
footnote_font_size = "0.9em",
footnote_position_bottom = "3em",
footnote_font_size = "0.9rem",
footnote_position_bottom = "60px",
left_column_subtle_color = "#777",
left_column_selected_color = "#000",
blockquote_left_border_color = "lightgray",
table_border_color = "#666",
table_row_border_color = "#ddd",
table_row_even_background_color = "#eee",
text_font_size = "20px",
header_h1_font_size = "55px",
header_h2_font_size = "45px",
header_h3_font_size = "35px",
base_font_size = "20px",
text_font_size = "1rem",
header_h1_font_size = "2.75rem",
header_h2_font_size = "2.25rem",
header_h3_font_size = "1.75rem",
header_background_auto = FALSE,
header_background_color = header_color,
header_background_text_color = background_color,
header_background_padding = "2rem 4rem 1.5rem 4rem",
header_background_content_padding_top = "7rem",
header_background_ignore_classes = c("normal", "inverse", "title", "middle", "bottom"),
text_slide_number_font_size = "0.9em",
text_slide_number_font_size = "0.9rem",
text_font_google = NULL,
text_font_family = "'Droid Serif'",
text_font_weight = "normal",
@@ -62,7 +63,7 @@ style_xaringan(
header_font_url = "https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz",
code_font_google = NULL,
code_font_family = "'Source Code Pro'",
code_font_size = "0.9em",
code_font_size = "0.9rem",
code_font_url = "https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700",
code_font_family_fallback = "'Lucida Console', Monaco",
colors = NULL,
@@ -84,7 +85,7 @@ style_xaringan(

\item{text_slide_number_color}{Slide Number Color. Defaults to \code{inverse_background_color}. Modifies the \code{.remark-slide-number} class.}

\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 1rem 4rem 1rem 4rem. Modifies the \code{.remark-slide-content} class.}
\item{padding}{Slide Padding in \verb{top right [bottom left]} format. Defaults to 16px 64px 16px 64px. Modifies the \code{.remark-slide-content} class.}

\item{background_image}{Background image applied to each \emph{and every} slide. Set \code{title_slide_background_image = "none"} to remove the background image from the title slide. Defaults to \code{NULL}. Modifies the \code{.remark-slide-content} class.}

@@ -98,7 +99,7 @@ style_xaringan(

\item{code_inline_background_color}{Inline Code Background Color. Defaults to \code{NULL}. Modifies the \code{.remark-inline-code} class.}

\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1em. Modifies the \code{.remark-inline-code} class.}
\item{code_inline_font_size}{Inline Code Text Font Size. Defaults to 1rem. Modifies the \code{.remark-inline-code} class.}

\item{inverse_background_color}{Inverse Background Color. Defaults to #272822. Modifies the \code{.inverse} class.}

@@ -120,9 +121,9 @@ style_xaringan(

\item{footnote_color}{Footnote text color (if \code{NA}, then it will be the same color as \code{text_color}). Defaults to \code{NULL}. Modifies the \code{.footnote} class.}

\item{footnote_font_size}{Footnote font size. Defaults to 0.9em. Modifies the \code{.footnote} class.}
\item{footnote_font_size}{Footnote font size. Defaults to 0.9rem. Modifies the \code{.footnote} class.}

\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 3em. Modifies the \code{.footnote} class.}
\item{footnote_position_bottom}{Footnote location from bottom of screen. Defaults to 60px. Modifies the \code{.footnote} class.}

\item{left_column_subtle_color}{Left Column Text (not last). Defaults to #777. Modifies the \verb{.left-column h2, .left-column h3} classes.}

@@ -136,13 +137,15 @@ style_xaringan(

\item{table_row_even_background_color}{Table Even Row Background Color. Defaults to #eee. Modifies the \verb{thead, tfoot, tr:nth-child(even)} elements.}

\item{text_font_size}{Slide Body Text Font Size. Defaults to 20px. Modifies the \code{.remark-slide-content} class.}
\item{base_font_size}{Base Font Size for All Slide Elements (must be \code{px}). Defaults to 20px. Modifies the \code{html} element.}

\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 55px. Modifies the \verb{.remark-slide-content h1} class.}
\item{text_font_size}{Slide Body Text Font Size. Defaults to 1rem. Modifies the \code{.remark-slide-content} class.}

\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 45px. Modifies the \verb{.remark-slide-content h2} class.}
\item{header_h1_font_size}{h1 Header Text Font Size. Defaults to 2.75rem. Modifies the \verb{.remark-slide-content h1} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 35px. Modifies the \verb{.remark-slide-content h3} class.}
\item{header_h2_font_size}{h2 Header Text Font Size. Defaults to 2.25rem. Modifies the \verb{.remark-slide-content h2} class.}

\item{header_h3_font_size}{h3 Header Text Font Size. Defaults to 1.75rem. Modifies the \verb{.remark-slide-content h3} class.}

\item{header_background_auto}{Add background under slide title automatically for h1 header elements. If not enabled, use \code{class: header_background} to enable. Defaults to \code{FALSE}.}

@@ -156,7 +159,7 @@ style_xaringan(

\item{header_background_ignore_classes}{Slide Classes Where Header with Background will not be Applied. Defaults to \code{c('normal', 'inverse', 'title', 'middle', 'bottom')}. Modifies the \code{.remark-slide-content} class.}

\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-slide-number} class.}
\item{text_slide_number_font_size}{Slide Number Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-slide-number} class.}

\item{text_font_google}{Use \code{google_font()} to specify body font. Defaults to \code{NULL}. Modifies the \code{body} element.}

@@ -182,7 +185,7 @@ style_xaringan(

\item{code_font_family}{Code Font Family. Defaults to 'Source Code Pro'. Modifies the \verb{.remark-code, .remark-inline-code} classes.}

\item{code_font_size}{Code Text Font Size. Defaults to 0.9em. Modifies the \code{.remark-inline} class.}
\item{code_font_size}{Code Text Font Size. Defaults to 0.9rem. Modifies the \code{.remark-inline} class.}

\item{code_font_url}{Code Font URL. Defaults to https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700. Modifies the \verb{@import url} elements.}


+ 8
- 0
tests/testthat/test-style_xaringan.R Просмотреть файл

@@ -6,3 +6,11 @@ test_that("style_xaringan() writes to specified outfile", {
expect_true(file.exists(tmpfile))
expect_true(grepl("xaringanthemer", readLines(tmpfile)[3]))
})

test_that("style_xaringan() warns if base_font_size is not absolute", {
tmpfile <- tempfile(fileext = ".css")
expect_warning(
style_xaringan(outfile = tmpfile, base_font_size = "1em"),
"absolute units"
)
})

Загрузка…
Отмена
Сохранить