How to change font color


I'm trying to change the font color of my shiny app.
I've tried passing ```tags$head(tags$style("#text1{color: red; font-size: 20px; font-style: italic;}"))

in my ui but it doesn't change anything.

I'm using a shinytheme and almost all the text of my app comes from markdowns (I'm using includeMarkdown).

Do you want to change the style of a class of text like Header 1, or the default for all text.
To change all body text, I would use

tags$head(tags$style('body {color:red;}')),

To change all paragraphs

tags$head(tags$style('p {color:red;}')),

To change Header 1

tags$head(tags$style('h1 {color:red;}')),

The #text1 in your example affects only the element with the id set to text1

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.