Skip to content
This repository has been archived by the owner on Sep 3, 2022. It is now read-only.

Self-hosted material icons and web fonts #1313

Merged
merged 2 commits into from
Apr 12, 2017

Conversation

yebrahim
Copy link
Contributor

@yebrahim yebrahim commented Apr 9, 2017

Self-hosting the icons and fonts gives us the following:

  • Better containment. Running Datalab now takes one less runtime dependency. If you're running Datalab while offline, for example, you'd get something like:
    image
  • Small improvement in load time locally, although loading these fonts on an SSH connection from GCE will take a little longer. However, browsers typically cache fonts after first visit.
  • Better support for automated tests in headless browsers. We're looking to add this at some point, but the latest stable phantomjs does not support rendering web fonts in screenshots.


/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should there be a blank line here, as there is between the lines just below?

Copy link
Contributor Author

@yebrahim yebrahim Apr 12, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed by removing all empty lines.

font-style: normal;
font-weight: 400;
src: url('source-code-pro-v6-latin-regular.eot'); /* IE9 Compat Modes */
src: local('Source Code Pro'), local('SourceCodePro-Regular'),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the name 'SourceCodePro-Regular' required by some other use? On line 43 you use 'OpenSans', sans '-Regular'. Perhaps this should just be 'SourceCodePro' to match 'OpenSans'. Or maybe 'OpenSans' should be 'OpenSans-Regular'.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not actually sure, these were auto-generated, and I'm not comfortable changing things here since they're not very easy to testing because of the browser matrix.

@yebrahim yebrahim merged commit 9f322dd into googledatalab:master Apr 12, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants