😎 Give your xaringan slides some style
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

371 line
21KB

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