diff --git a/_common.R b/_common.R index 6a17550..e1f3844 100644 --- a/_common.R +++ b/_common.R @@ -13,13 +13,10 @@ knitr::opts_chunk$set( options( dplyr.print_min = 6, dplyr.print_max = 6, - stringr.view_n = 10 -) - -# Activate crayon output -options( - #crayon.enabled = TRUE, - pillar.bold = TRUE, + stringr.view_n = 10, + # Activate crayon output - temporarily disabled for quarto + # crayon.enabled = TRUE, + pillar.bold = TRUE ) ggplot2::theme_set(ggplot2::theme_gray(12)) @@ -33,8 +30,15 @@ status <- function(type) { stop("Invalid `type`", call. = FALSE) ) + class <- switch(type, + polishing = "note", + restructuring = "important", + drafting = "important", + complete = "note" + ) + cat(paste0( - "::: status\n", + "::: callout-", class, "\n", "You are reading the work-in-progress second edition of R for Data Science. ", "This chapter ", status, ". ", "You can find the complete first edition at .\n", diff --git a/r4ds.scss b/r4ds.scss index 2a4680d..ea7d950 100644 --- a/r4ds.scss +++ b/r4ds.scss @@ -12,18 +12,6 @@ img.quarto-cover-image { box-shadow: 0 .5rem 1rem rgba(0,0,0,.15); } -/* status box styling */ - -.status { - border: 2px solid #637238; - padding: 1em; - margin-bottom: 1em; -} - -.status p { - margin-bottom: 0; -} - /* Headings ------------------------------------------------------ */ h2 {