holly_H8s_Snake_Case
holly_H8s_Snake_Case

Reputation: 31

How do I change the colors in the rmdtemplate material theme?

I am using the rmdformats::material package. What is the CSS to change the top banner color?

Here is my code.

---
title: "test"
date: "hi"
output:
  rmdformats::material:
    self_contained: no
    css: style.css
---


```{r knitr_init, echo=FALSE, cache=FALSE}
library(knitr)
library(rmdformats)

```

# test

Here is part of my CSS:

.page h1, .h1 {
    color: #971b72 ;
}

Upvotes: 1

Views: 365

Answers (2)

Susan Switzer
Susan Switzer

Reputation: 1922

You can control the background color of the header in your .css file with the following code:

.header-panel {
    background-color: #971b72;
}

Upvotes: 0

MrFlick
MrFlick

Reputation: 206232

The banner color seems to be set as the background of the .header-panel div. You should set your CSS to

.header-panel {
    background-color: #971b72 ;
}

Upvotes: 1

Related Questions