# WARNING - Generated by {fusen} from dev/flat_plots.Rmd: do not edit by hand # nolint: line_length_linter.

#' Format color
#' 
#' Format color for matrix regulation table
#' @param couleurs A character vector of CSS colours (one per cell) used as the cell background.
#' @import formattable
#' @return A formattable `formatter` (span) that renders a coloured, centered cell.
#'
#' @noRd
format_color <- function(couleurs){
  formatter(
      "span",
      style = x ~ style(
        display            = "block",
        "border-radius"    = "4px",
        "padding"          = "4px",
        "background-color" = couleurs,
        color              = "white",
        "text-align"       = "center",
        "font-weight"      = "bold"
      )
  )
}
