I have been working periodically on getting my research and teaching pages served on gitpages [maliciously] compliant with our university communication policy.
I’ve been using the old rundocs/jekyll-rtd-theme which is no longer on GitHub but has been thankfully archived by clearpathrobotics team which is now at clearpathrobotics/jekyll-rtd-theme (with many thanks for their preserving it!)
While I have been able to add logos and change the colors to match our branding, the changing fonts (Body to “Open Sans,” Header to something other than “Roboto” but our branding police say that “Palatino Linotype” could be tolerated) have continued to elude me despite taking guidance from stackoverflow, reddit and all the other “just google it” resources.
Nothing I change has led to any traction in changing the main web area of the resulting pages. Given the diversity in advice in looking at the existing online troubleshooting, there appear to be many variations on how to change the fonts between various jekyll themes. My attempts to locally impose my own modifications (successful for colors) have included locally adding my own sass/_font-face.scss & sass/_variables.scss to micromanaging a local copy of the sass/assets/css/theme.min.css. So far I continue to be stuck with “Lato” and “Roboto-Slab.”
Does anyone have a starting point that can at least identify where the font definitions in the original jekyll-rtd-theme are actually modifiable by a user remotely accessing them?
I have indeed: The theme’s default fonts, Lato and Roboto-Slab, and references to them (e.g., $body-font & $head-font) that persist in any modification I attempt are only in the files below:
Explicit use of the font names (“Lato” & "Roboto-Slab):
Attempts to create new versions of these files in my local github pages have not met with success in altering the default fonts. (Though again, I was successful in altering the background color of the sidebar and adding our university logo)
I don’t think it is using the sass files from what I can tell - there was probably some other build process that used them? and that is where you get the theme.min.css file.
It looks like the intention is to add other styles to an extras file inside the includes - jekyll-rtd-theme/_includes/extra/styles.scss
try adding something in there and see if it does something. My guess is that file loads last and will override anything set previously.
I could be wrong though, I just poked around for a couple minutes and can’t say I really understand what is going on.
Your best bet is to try and understand what loads the css which is where I found that - so looking at the layout which loads some includes and checking the includes to see what loads the css.