😎 Give your xaringan slides some style
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

362 lines
21KB

  1. # Generated by inst/scripts/generate_theme_functions.R: do not edit by hand
  2. #' @param base_color Monotone base color, works best with a strong color.
  3. #' Defaults to #23395b. Used in multiple CSS rules. The value of this
  4. #' variable is also stored as a CSS variable that can be referenced with
  5. #' `var(--base)` in any argument of a style function or in custom CSS.
  6. #' @param white_color Brightest color used, default is a very light version of
  7. #' `base_color`. Defaults to `lighten_color(base_color, 0.9)`. Used in
  8. #' multiple CSS rules. The value of this variable is also stored as a CSS
  9. #' variable that can be referenced with `var(--white)` in any argument of a
  10. #' style function or in custom CSS.
  11. #' @param black_color Darkest color used, default is a very dark, version of
  12. #' `base_color`. Defaults to `darken_color(base_color, 0.3)`. Used in
  13. #' multiple CSS rules. The value of this variable is also stored as a CSS
  14. #' variable that can be referenced with `var(--black)` in any argument of a
  15. #' style function or in custom CSS.
  16. #' @param text_color Text Color. Defaults to `black_color`. Modifies the `body`
  17. #' element. The value of this variable is also stored as a CSS variable that
  18. #' can be referenced with `var(--text_color)` in any argument of a style
  19. #' function or in custom CSS.
  20. #' @param header_color Header Color. Defaults to `base_color`. Modifies the
  21. #' `h1, h2, h3` elements. The value of this variable is also stored as a CSS
  22. #' variable that can be referenced with `var(--header-color)` in any argument
  23. #' of a style function or in custom CSS.
  24. #' @param background_color Slide Background Color. Defaults to `white_color`.
  25. #' Modifies the `.remark-slide-content` class. The value of this variable is
  26. #' also stored as a CSS variable that can be referenced with
  27. #' `var(--background-color)` in any argument of a style function or in custom
  28. #' CSS.
  29. #' @param link_color Link Color. Defaults to `base_color`. Modifies the
  30. #' `a, a > code` elements. The value of this variable is also stored as a CSS
  31. #' variable that can be referenced with `var(--link-color)` in any argument
  32. #' of a style function or in custom CSS.
  33. #' @param text_bold_color Bold Text Color. Defaults to `base_color`. Modifies
  34. #' the `strong` element. The value of this variable is also stored as a CSS
  35. #' variable that can be referenced with `var(--text-bold-color)` in any
  36. #' argument of a style function or in custom CSS.
  37. #' @param text_slide_number_color Slide Number Color. Defaults to `base_color`.
  38. #' Modifies the `.remark-slide-number` class.
  39. #' @param padding Slide Padding in `top right [bottom left]` format. Defaults
  40. #' to 16px 64px 16px 64px. Modifies the `.remark-slide-content` class.
  41. #' Accepts CSS
  42. #' [padding](https://developer.mozilla.org/en-US/docs/Web/CSS/padding)
  43. #' property values.
  44. #' @param background_image Background image applied to each *and every* slide.
  45. #' Set `title_slide_background_image = "none"` to remove the background image
  46. #' from the title slide. Defaults to `NULL`. Modifies the
  47. #' `.remark-slide-content` class.
  48. #' @param background_size Background image size, requires `background_image` to
  49. #' be set. If `background_image` is set, `background_size` will default to
  50. #' `cover` so the background fills the screen. If both `background_image` and
  51. #' `background_position` are set, will default to 100 percent. Defaults to
  52. #' `NULL`. Modifies the `.remark-slide-content` class. Accepts CSS
  53. #' [background-size](https://developer.mozilla.org/en-US/docs/Web/CSS/background-size)
  54. #' property values.
  55. #' @param background_position Background image position, requires
  56. #' `background_image` to be set, and it is recommended to adjust
  57. #' `background_size`. Defaults to `NULL`. Modifies the
  58. #' `.remark-slide-content` class. Accepts CSS
  59. #' [background-position](https://developer.mozilla.org/en-US/docs/Web/CSS/background-position)
  60. #' property values.
  61. #' @param code_highlight_color Code Line Highlight. Defaults to
  62. #' rgba(255,255,0,0.5). Modifies the `.remark-code-line-highlighted` class.
  63. #' The value of this variable is also stored as a CSS variable that can be
  64. #' referenced with `var(--code-highlight-color)` in any argument of a style
  65. #' function or in custom CSS.
  66. #' @param code_inline_color Inline Code Color. Defaults to `base_color`.
  67. #' Modifies the `.remark-inline-code` class.
  68. #' @param code_inline_background_color Inline Code Background Color. Defaults
  69. #' to `NULL`. Modifies the `.remark-inline-code` class.
  70. #' @param code_inline_font_size Inline Code Text Font Size. Defaults to 1em.
  71. #' Modifies the `.remark-inline-code` class. Accepts CSS
  72. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  73. #' property values. The value of this variable is also stored as a CSS
  74. #' variable that can be referenced with `var(--code-inline-font-size)` in any
  75. #' argument of a style function or in custom CSS.
  76. #' @param inverse_background_color Inverse Background Color. Defaults to
  77. #' `base_color`. Modifies the `.inverse` class. The value of this variable is
  78. #' also stored as a CSS variable that can be referenced with
  79. #' `var(--inverse-background-color)` in any argument of a style function or
  80. #' in custom CSS.
  81. #' @param inverse_text_color Inverse Text Color. Defaults to `white_color`.
  82. #' Modifies the `.inverse` class. The value of this variable is also stored
  83. #' as a CSS variable that can be referenced with `var(--inverse-text-color)`
  84. #' in any argument of a style function or in custom CSS.
  85. #' @param inverse_text_shadow Enables Shadow on text of inverse slides.
  86. #' Defaults to `FALSE`. Modifies the `.inverse` class.
  87. #' @param inverse_header_color Inverse Header Color. Defaults to
  88. #' `inverse_text_color`. Modifies the `.inverse h1, .inverse h2, .inverse h3`
  89. #' classes. The value of this variable is also stored as a CSS variable that
  90. #' can be referenced with `var(--inverse-header-color)` in any argument of a
  91. #' style function or in custom CSS.
  92. #' @param inverse_link_color Inverse Link Color. Defaults to `link_color`.
  93. #' Modifies the `.inverse a, .inverse a > code` classes. The value of this
  94. #' variable is also stored as a CSS variable that can be referenced with
  95. #' `var(--inverse-link-color)` in any argument of a style function or in
  96. #' custom CSS.
  97. #' @param title_slide_text_color Title Slide Text Color. Defaults to
  98. #' `inverse_text_color`. Modifies the `.title-slide` class. The value of this
  99. #' variable is also stored as a CSS variable that can be referenced with
  100. #' `var(--title-slide-text-color)` in any argument of a style function or in
  101. #' custom CSS.
  102. #' @param title_slide_background_color Title Slide Background Color. Defaults
  103. #' to `inverse_background_color`. Modifies the `.title-slide` class. The
  104. #' value of this variable is also stored as a CSS variable that can be
  105. #' referenced with `var(--title-slide-background-color)` in any argument of a
  106. #' style function or in custom CSS.
  107. #' @param title_slide_background_image Title Slide Background Image URL.
  108. #' Defaults to `NULL`. Modifies the `.title-slide` class.
  109. #' @param title_slide_background_size Title Slide Background Image Size,
  110. #' defaults to "cover" if background image is set. Defaults to `NULL`.
  111. #' Modifies the `.title-slide` class. Accepts CSS
  112. #' [background-size](https://developer.mozilla.org/en-US/docs/Web/CSS/background-size)
  113. #' property values.
  114. #' @param title_slide_background_position Title Slide Background Image
  115. #' Position. Defaults to `NULL`. Modifies the `.title-slide` class. Accepts
  116. #' CSS
  117. #' [background-position](https://developer.mozilla.org/en-US/docs/Web/CSS/background-position)
  118. #' property values.
  119. #' @param footnote_color Footnote text color (if `NA`, then it will be the same
  120. #' color as `text_color`). Defaults to `NULL`. Modifies the `.footnote`
  121. #' class.
  122. #' @param footnote_font_size Footnote font size. Defaults to 0.9em. Modifies
  123. #' the `.footnote` class. Accepts CSS
  124. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  125. #' property values.
  126. #' @param footnote_position_bottom Footnote location from bottom of screen.
  127. #' Defaults to 60px. Modifies the `.footnote` class. Accepts CSS
  128. #' [position](https://developer.mozilla.org/en-US/docs/Web/CSS/position_value)
  129. #' property values.
  130. #' @param left_column_subtle_color Left Column Text (not last). Defaults to
  131. #' `apply_alpha(base_color, 0.6)`. Modifies the
  132. #' `.left-column h2, .left-column h3` classes.
  133. #' @param left_column_selected_color Left Column Current Selection. Defaults to
  134. #' `base_color`. Modifies the
  135. #' `.left-column h2:last-of-type, .left-column h3:last-child` classes.
  136. #' @param blockquote_left_border_color Blockquote Left Border Color. Defaults
  137. #' to `apply_alpha(base_color, 0.5)`. Modifies the `blockquote` element.
  138. #' @param table_border_color Table top/bottom border. Defaults to #666.
  139. #' Modifies the `table: border-top, border-bottom` elements.
  140. #' @param table_row_border_color Table row inner bottom border. Defaults to
  141. #' #ddd. Modifies the `table thead th: border-bottom` elements.
  142. #' @param table_row_even_background_color Table Even Row Background Color.
  143. #' Defaults to `lighten_color(base_color, 0.8)`. Modifies the
  144. #' `thead, tfoot, tr:nth-child(even)` elements.
  145. #' @param base_font_size Base Font Size for All Slide Elements (must be `px`).
  146. #' Defaults to 20px. Modifies the `html` element. The value of this variable
  147. #' is also stored as a CSS variable that can be referenced with
  148. #' `var(--base-font-size)` in any argument of a style function or in custom
  149. #' CSS.
  150. #' @param text_font_size Slide Body Text Font Size. Defaults to 1rem. Modifies
  151. #' the `.remark-slide-content` class. Accepts CSS
  152. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  153. #' property values. The value of this variable is also stored as a CSS
  154. #' variable that can be referenced with `var(--text-font-size)` in any
  155. #' argument of a style function or in custom CSS.
  156. #' @param header_h1_font_size h1 Header Text Font Size. Defaults to 2.75rem.
  157. #' Modifies the `.remark-slide-content h1` class. Accepts CSS
  158. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  159. #' property values. The value of this variable is also stored as a CSS
  160. #' variable that can be referenced with `var(--header-h1-font-size)` in any
  161. #' argument of a style function or in custom CSS.
  162. #' @param header_h2_font_size h2 Header Text Font Size. Defaults to 2.25rem.
  163. #' Modifies the `.remark-slide-content h2` class. Accepts CSS
  164. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  165. #' property values. The value of this variable is also stored as a CSS
  166. #' variable that can be referenced with `var(--header-h2-font-size)` in any
  167. #' argument of a style function or in custom CSS.
  168. #' @param header_h3_font_size h3 Header Text Font Size. Defaults to 1.75rem.
  169. #' Modifies the `.remark-slide-content h3` class. Accepts CSS
  170. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  171. #' property values. The value of this variable is also stored as a CSS
  172. #' variable that can be referenced with `var(--header-h3-font-size)` in any
  173. #' argument of a style function or in custom CSS.
  174. #' @param header_background_auto Add background under slide title automatically
  175. #' for h1 header elements. If not enabled, use `class: header_background` to
  176. #' enable. Defaults to `FALSE`.
  177. #' @param header_background_color Background Color for h1 Header with
  178. #' Background. Defaults to `header_color`. Modifies the
  179. #' `.remark-slide-content h1` class. The value of this variable is also
  180. #' stored as a CSS variable that can be referenced with
  181. #' `var(--header-background-color)` in any argument of a style function or in
  182. #' custom CSS.
  183. #' @param header_background_text_color Text Color for h1 Header with
  184. #' Background. Defaults to `background_color`. Modifies the
  185. #' `.remark-slide-content h1` class. The value of this variable is also
  186. #' stored as a CSS variable that can be referenced with
  187. #' `var(--header-background-text-color)` in any argument of a style function
  188. #' or in custom CSS.
  189. #' @param header_background_padding Padding for h1 Header with Background.
  190. #' Defaults to `NULL`. Modifies the `.remark-slide-content h1` class. Accepts
  191. #' CSS [padding](https://developer.mozilla.org/en-US/docs/Web/CSS/padding)
  192. #' property values.
  193. #' @param header_background_content_padding_top Top Padding for Content in
  194. #' Slide with Header with Background. Defaults to 7rem. Modifies the
  195. #' `.remark-slide-content` class.
  196. #' @param header_background_ignore_classes Slide Classes Where Header with
  197. #' Background will not be Applied. Defaults to
  198. #' `c('normal', 'inverse', 'title', 'middle', 'bottom')`. Modifies the
  199. #' `.remark-slide-content` class.
  200. #' @param text_slide_number_font_size Slide Number Text Font Size. Defaults to
  201. #' 0.9rem. Modifies the `.remark-slide-number` class. Accepts CSS
  202. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  203. #' property values.
  204. #' @param text_font_google Use `google_font()` to specify body font. Defaults
  205. #' to `NULL`. Modifies the `body` element.
  206. #' @param text_font_family Body Text Font Family (xaringan default is
  207. #' `'Droid Serif'`). Defaults to
  208. #' `xaringanthemer_font_default("text_font_family")`. Modifies the `body`
  209. #' element. The value of this variable is also stored as a CSS variable that
  210. #' can be referenced with `var(--text-font-family)` in any argument of a
  211. #' style function or in custom CSS.
  212. #' @param text_font_weight Body Text Font Weight. Defaults to
  213. #' `xaringanthemer_font_default("text_font_weight")`. Modifies the `body`
  214. #' element. Accepts CSS
  215. #' [font-weight](https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight)
  216. #' property values.
  217. #' @param text_bold_font_weight Body Bold Text Font Weight. Defaults to bold.
  218. #' Modifies the `strong` element.
  219. #' @param text_font_url Body Text Font URL(s). Defaults to
  220. #' `xaringanthemer_font_default("text_font_url")`. Modifies the
  221. #' `@import url()` elements.
  222. #' @param text_font_family_fallback Body Text Font Fallbacks. Defaults to
  223. #' `xaringanthemer_font_default("text_font_family_fallback")`. Modifies the
  224. #' `body` element. The value of this variable is also stored as a CSS
  225. #' variable that can be referenced with `var(--text-font-family-fallback)` in
  226. #' any argument of a style function or in custom CSS.
  227. #' @param text_font_base Body Text Base Font (Total Failure Fallback). Defaults
  228. #' to sans-serif. Modifies the `body` element. The value of this variable is
  229. #' also stored as a CSS variable that can be referenced with
  230. #' `var(--text-font-base)` in any argument of a style function or in custom
  231. #' CSS.
  232. #' @param header_font_google Use `google_font()` to specify header font.
  233. #' Defaults to `NULL`. Modifies the `body` element.
  234. #' @param header_font_family Header Font Family (xaringan default is
  235. #' `'Yanone Kaffeesatz'`). Defaults to
  236. #' `xaringanthemer_font_default("header_font_family")`. Modifies the
  237. #' `h1, h2, h3` elements. The value of this variable is also stored as a CSS
  238. #' variable that can be referenced with `var(--header-font-family)` in any
  239. #' argument of a style function or in custom CSS.
  240. #' @param header_font_weight Header Font Weight. Defaults to
  241. #' `xaringanthemer_font_default("header_font_weight")`. Modifies the
  242. #' `h1, h2, h3` elements. Accepts CSS
  243. #' [font-weight](https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight)
  244. #' property values.
  245. #' @param header_font_family_fallback Header Font Family Fallback. Defaults to
  246. #' Georgia, serif. Modifies the `h1, h2, h3` elements. The value of this
  247. #' variable is also stored as a CSS variable that can be referenced with
  248. #' `var(--header-font-family-fallback)` in any argument of a style function
  249. #' or in custom CSS.
  250. #' @param header_font_url Header Font URL. Defaults to
  251. #' `xaringanthemer_font_default("header_font_url")`. Modifies the
  252. #' `@import url` elements.
  253. #' @param code_font_google Use `google_font()` to specify code font. Defaults
  254. #' to `NULL`. Modifies the `body` element.
  255. #' @param code_font_family Code Font Family. Defaults to
  256. #' `xaringanthemer_font_default("code_font_family")`. Modifies the
  257. #' `.remark-code, .remark-inline-code` classes. The value of this variable is
  258. #' also stored as a CSS variable that can be referenced with
  259. #' `var(--code-font-family)` in any argument of a style function or in custom
  260. #' CSS.
  261. #' @param code_font_size Code Text Font Size. Defaults to 0.9rem. Modifies the
  262. #' `.remark-inline` class. Accepts CSS
  263. #' [font-size](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size)
  264. #' property values. The value of this variable is also stored as a CSS
  265. #' variable that can be referenced with `var(--code-font-size)` in any
  266. #' argument of a style function or in custom CSS.
  267. #' @param code_font_url Code Font URL. Defaults to
  268. #' `xaringanthemer_font_default("code_font_url")`. Modifies the `@import url`
  269. #' elements.
  270. #' @param code_font_family_fallback Code Font Fallback. Defaults to
  271. #' `xaringanthemer_font_default("code_font_family_fallback")`. Modifies the
  272. #' `.remark-code, .remark-inline-code` classes.
  273. #' @param link_decoration Text decoration of links. Defaults to none. Modifies
  274. #' the `a, a > code` elements. Accepts CSS
  275. #' [text-decoration](https://developer.mozilla.org/en-US/docs/Web/CSS/text-decoration)
  276. #' property values.
  277. #' @template theme_params
  278. #' @template style-usage
  279. #' @template style_mono_light
  280. #' @family Monotone themes
  281. #' @export
  282. style_mono_light <- function(
  283. base_color = "#23395b",
  284. white_color = lighten_color(base_color, 0.9),
  285. black_color = darken_color(base_color, 0.3),
  286. text_color = black_color,
  287. header_color = base_color,
  288. background_color = white_color,
  289. link_color = base_color,
  290. text_bold_color = base_color,
  291. text_slide_number_color = base_color,
  292. padding = "16px 64px 16px 64px",
  293. background_image = NULL,
  294. background_size = NULL,
  295. background_position = NULL,
  296. code_highlight_color = "rgba(255,255,0,0.5)",
  297. code_inline_color = base_color,
  298. code_inline_background_color = NULL,
  299. code_inline_font_size = "1em",
  300. inverse_background_color = base_color,
  301. inverse_text_color = white_color,
  302. inverse_text_shadow = FALSE,
  303. inverse_header_color = inverse_text_color,
  304. inverse_link_color = link_color,
  305. title_slide_text_color = inverse_text_color,
  306. title_slide_background_color = inverse_background_color,
  307. title_slide_background_image = NULL,
  308. title_slide_background_size = NULL,
  309. title_slide_background_position = NULL,
  310. footnote_color = NULL,
  311. footnote_font_size = "0.9em",
  312. footnote_position_bottom = "60px",
  313. left_column_subtle_color = apply_alpha(base_color, 0.6),
  314. left_column_selected_color = base_color,
  315. blockquote_left_border_color = apply_alpha(base_color, 0.5),
  316. table_border_color = "#666",
  317. table_row_border_color = "#ddd",
  318. table_row_even_background_color = lighten_color(base_color, 0.8),
  319. base_font_size = "20px",
  320. text_font_size = "1rem",
  321. header_h1_font_size = "2.75rem",
  322. header_h2_font_size = "2.25rem",
  323. header_h3_font_size = "1.75rem",
  324. header_background_auto = FALSE,
  325. header_background_color = header_color,
  326. header_background_text_color = background_color,
  327. header_background_padding = NULL,
  328. header_background_content_padding_top = "7rem",
  329. header_background_ignore_classes = c('normal', 'inverse', 'title', 'middle', 'bottom'),
  330. text_slide_number_font_size = "0.9rem",
  331. text_font_google = NULL,
  332. text_font_family = xaringanthemer_font_default("text_font_family"),
  333. text_font_weight = xaringanthemer_font_default("text_font_weight"),
  334. text_bold_font_weight = "bold",
  335. text_font_url = xaringanthemer_font_default("text_font_url"),
  336. text_font_family_fallback = xaringanthemer_font_default("text_font_family_fallback"),
  337. text_font_base = "sans-serif",
  338. header_font_google = NULL,
  339. header_font_family = xaringanthemer_font_default("header_font_family"),
  340. header_font_weight = xaringanthemer_font_default("header_font_weight"),
  341. header_font_family_fallback = "Georgia, serif",
  342. header_font_url = xaringanthemer_font_default("header_font_url"),
  343. code_font_google = NULL,
  344. code_font_family = xaringanthemer_font_default("code_font_family"),
  345. code_font_size = "0.9rem",
  346. code_font_url = xaringanthemer_font_default("code_font_url"),
  347. code_font_family_fallback = xaringanthemer_font_default("code_font_family_fallback"),
  348. link_decoration = "none",
  349. colors = NULL,
  350. extra_css = NULL,
  351. extra_fonts = NULL,
  352. outfile = "xaringan-themer.css"
  353. ) {
  354. # DO NOT EDIT - Generated from inst/scripts/generate_theme_functions.R
  355. base_color <- unname(base_color)
  356. white_color <- unname(white_color)
  357. black_color <- unname(black_color)
  358. colors <- c(base = base_color, white = white_color, black = black_color, colors)
  359. eval(parse(text = call_style_xaringan()))
  360. }