brson / temple-of-rust

Tutum. Simul. Celerem.
http://brson.github.io/temple-of-rust
Other
25 stars 8 forks source link

CSS: Fix mixed content, add font fallback #3

Closed 8573 closed 8 years ago

8573 commented 8 years ago

In the CSS stylesheet temple-of-rust.css, in the rule for the body element, the property font-family is specified with only a single value, 'Fira Mono', with no fallback value for use in the event that the typeface Fira Mono is unavailable; for me, this resulted in the text being rendered in the typeface Liberation Serif.

In the same stylesheet, an @import rule is specified to load the definition of the typeface Fira Mono from Google Fonts; this rule is specified such that the resource is to be loaded via unsecured HTTP.

If the temple-of-rust Web-page is loaded via HTTPS, this definition of the @import rule may result in mixed-content errors, which may result in the viewer's Web browser refusing to load the resource, as it does for me in Chromium 52.

These patches change the @import rule to instead load the resource via HTTPS, and change the font-family property to fall back to the viewer's default monospace typeface in case Fira Mono is still unavailable.

brson commented 8 years ago

Thanks!

8573 commented 8 years ago

Thanks for merging!