I am formatting a gt table to add a colour legend in the bottom of the table with
tab_source_note(html('<pre style="display: inline;"><span style="background-color: red;"
> </span> = Up</pre> <pre><span style="background-color: #FFEFA3;"
> </span> = Maintain</pre> <pre><span style="background-color: #A65176;"
> </span> = Down</pre>')')
I get the caption to appear, but it is in a column, and I would like it to be in a single line of text.
If anyone is interesed, I got this solution, also change font and size:
tab_source_note(html('<pre style="display: inline;font-family: Avenir, Verdana, sans-serif; font-size: 15px"><span style="background-color: #FF2F2F;"
> </span> = Up</pre> <pre style="display: inline;font-family: Avenir, Verdana, sans-serif; font-size: 15px"><span style="background-color: #FFEFA3;"
> </span> = Maintain</pre> <pre style="display: inline;font-family: Avenir, Verdana, sans-serif; font-size: 15px"><span style="background-color: #A65176;"
> </span> = Down</pre>'))
system
Closed
3
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.